public interface EruptUserRepository extends org.springframework.data.jpa.repository.JpaRepository<EruptUser,Long>
| 限定符和类型 | 方法和说明 |
|---|---|
EruptUser |
findByAccount(String userId)
根据账号查询
|
List<EruptUser> |
findByAccountContainingOrNameContaining(String keywords,
String keyword1)
模糊匹配
|
List<EruptUser> |
findByAccountIn(Collection<String> accounts)
根据账号集合查询
|
List<EruptUser> |
findByEruptOrgId(Long orgId)
根据上级机构id查询
|
List<EruptUser> |
findByEruptOrgIdIsNull()
查询机构为空的人员
|
List<EruptUser> |
findByIsAdmin(boolean b)
查询超管用户
|
List<EruptUser> |
findByRoleIds(Collection<String> roleIds)
根据角色id查询数据
|
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getById, getOne, getReferenceById, saveAll, saveAllAndFlush, saveAndFlushList<EruptUser> findByAccountContainingOrNameContaining(String keywords, String keyword1)
keywords - @Query(value="from EruptUser where id in (select userId from EruptUserRole where roleId in (select id from EruptRole where code in :roleIds) ) ") List<EruptUser> findByRoleIds(Collection<String> roleIds)
roleIds - List<EruptUser> findByAccountIn(Collection<String> accounts)
Copyright © 2023. All rights reserved.