package com.yihu.jw.base.dao.role;

import com.yihu.jw.entity.base.role.RoleDO;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.repository.PagingAndSortingRepository;

import java.util.List;

/**
 * Dao - 角色
 * Created by progr1mmer on 2018/8/17.
 */
public interface RoleDao extends PagingAndSortingRepository<RoleDO, String>, JpaSpecificationExecutor<RoleDO> {

    RoleDO findByCode(String code);

    List<RoleDO> findByNameAndStatus(String name,Integer status);

    List<RoleDO> findByNameAndSaasIdAndStatus(String name,String saasId,Integer status);
}
