feat:(REQ-2227) 新增角色分组时,sort取同一个workspaceTypeCode的最大值

This commit is contained in:
lilong 2024-04-09 22:40:28 +08:00
parent 793f34c67b
commit ed3ac9e5f8

View File

@ -182,6 +182,7 @@ public class SaasRoleGroupServiceImpl implements SaasRoleGroupService {
Optional<SaasRoleGroup> last = saasRoleGroupDao.lambdaQuery()
.eq(SaasRoleGroup::getParentId, saasRoleGroup.getParentId())
.eq(SaasRoleGroup::getWorkspaceTypeCode, saasRoleGroup.getWorkspaceTypeCode())
.eq(SaasRoleGroup::getIsDelete, TableIsDeleteEnum.NORMAL.value)
.orderByDesc(SaasRoleGroup::getSort)
.last("limit 1")