package com.dtok.repository;
import com.dtok.entity.RolePermission;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import java.util.List;

/**
 * @Description  
 * @Author  C.J
 * @Date 2024-03-08 
 */

public interface RolePermissionRepository extends JpaRepository<RolePermission, String>, JpaSpecificationExecutor<RolePermission> {

    List<RolePermission> findRolePermissionsByRoleCode(String roleCode);

    void deleteAllByRoleCode(String roleCode);
}
