|
@@ -4,7 +4,6 @@ import java.util.List;
|
|
|
|
|
|
import org.springframework.data.domain.Page;
|
|
|
import org.springframework.data.domain.Pageable;
|
|
|
-import org.springframework.data.jpa.domain.Specification;
|
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
|
|
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
|
|
import org.springframework.data.jpa.repository.Modifying;
|
|
@@ -13,7 +12,6 @@ import org.springframework.data.repository.query.Param;
|
|
|
import org.springframework.data.repository.query.QueryByExampleExecutor;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
-import cn.com.qmth.examcloud.service.core.entity.Specialty;
|
|
|
import cn.com.qmth.examcloud.service.core.entity.User;
|
|
|
|
|
|
|
|
@@ -40,10 +38,10 @@ public interface UserRepo extends JpaRepository<User,Long>,QueryByExampleExecuto
|
|
|
|
|
|
@Query(nativeQuery = true,value = "SELECT DISTINCT * FROM ecs_core_user us, ecs_core_user_role ur WHERE us.id = ur.user_id And us.root_org_id = ? And ur.role_code = 'MARKER' And us.enable = 1")
|
|
|
List<User> findMarkerByRootOrgId(Long rootOrgId);
|
|
|
-
|
|
|
- @Query(value = "SELECT distinct * FROM ecs_core_user us, ecs_core_user_role ur WHERE us.id = ur.user_id " +
|
|
|
- "And us.root_org_id = :rootOrgId And ur.role_code = 'MARKER' And us.enable = 1 ORDER BY ?#{#pageable}",
|
|
|
- countQuery = "SELECT count(distinct us.id ) FROM ecs_core_user us, ecs_core_user_role ur WHERE us.id = ur.user_id " +"And us.root_org_id = :rootOrgId And ur.role_code = 'MARKER' And us.enable = 1 ORDER BY ?#{#pageable}",nativeQuery = true)
|
|
|
- Page<User> findMarkerByRootOrgId(@Param("rootOrgId")long rootOrgId, Pageable pageable);
|
|
|
|
|
|
+ @Query(value = "SELECT distinct * FROM ecs_core_user us, ecs_core_user_role ur WHERE us.id = ur.user_id " +
|
|
|
+ "And us.root_org_id = ? And ur.role_code = 'MARKER' And us.enable = 1 ORDER BY ?#{#pageable}",
|
|
|
+ countQuery = "SELECT count(distinct us.id) FROM ecs_core_user us, ecs_core_user_role ur WHERE us.id = ur.user_id " +
|
|
|
+ "And us.root_org_id = ? And ur.role_code = 'MARKER' And us.enable = 1 ORDER BY ?#{#pageable}",nativeQuery = true)
|
|
|
+ Page<User> findMarkerByRootOrgId(Long rootOrgId, Pageable pageable);
|
|
|
}
|