feat:(REQ-3282) 去掉已经废弃的代码
This commit is contained in:
parent
bbc702dcd4
commit
55a64d39b9
@ -60,27 +60,6 @@ public class SaasRoleDao extends ServiceImpl<SaasRoleMapper, SaasRole> {
|
|||||||
return this.getBaseMapper().listRoleUserByPermissionGroup(permissionGroupIdList, workspaceIds);
|
return this.getBaseMapper().listRoleUserByPermissionGroup(permissionGroupIdList, workspaceIds);
|
||||||
}
|
}
|
||||||
|
|
||||||
public SaasRole findRoleByTypeAndWorkspaceIdAndOuId(String roleType, Long workspaceId,
|
|
||||||
Long ouId) {
|
|
||||||
return this.lambdaQuery()
|
|
||||||
.eq(SaasRole::getRoleType, roleType)
|
|
||||||
.eq(SaasRole::getWorkspaceId, workspaceId)
|
|
||||||
.eq(SaasRole::getOwnerOuId, ouId)
|
|
||||||
.eq(SaasRole::getIsDelete, TableIsDeleteEnum.NORMAL.value)
|
|
||||||
.last(" limit 1").one();
|
|
||||||
}
|
|
||||||
|
|
||||||
public List<SaasRole> listCommonRoleByNameAndWorkspaceIdAndOuId(String name, Long workspaceId,
|
|
||||||
Long ouId) {
|
|
||||||
return lambdaQuery().eq(SaasRole::getName, name)
|
|
||||||
.eq(SaasRole::getWorkspaceId, workspaceId)
|
|
||||||
.eq(SaasRole::getOwnerOuId, ouId)
|
|
||||||
.eq(SaasRole::getRoleType, RoleTypeEnum.COMMON.getValue())
|
|
||||||
.eq(SaasRole::getIsDelete, TableIsDeleteEnum.NORMAL.value)
|
|
||||||
.select(SaasRole::getId)
|
|
||||||
.list();
|
|
||||||
}
|
|
||||||
|
|
||||||
public List<SaasRole> findRoleByName(Long ouId, Long workspaceId,List<Long> roleIds,
|
public List<SaasRole> findRoleByName(Long ouId, Long workspaceId,List<Long> roleIds,
|
||||||
List<String> roleNames) {
|
List<String> roleNames) {
|
||||||
return this.lambdaQuery().select(SaasRole::getId, SaasRole::getName, SaasRole::getRoleType)
|
return this.lambdaQuery().select(SaasRole::getId, SaasRole::getName, SaasRole::getRoleType)
|
||||||
|
|||||||
@ -54,13 +54,6 @@ public class SaasRoleGroupDao extends ServiceImpl<SaasRoleGroupMapper, SaasRoleG
|
|||||||
.update();
|
.update();
|
||||||
}
|
}
|
||||||
|
|
||||||
/** 弃用category_code 通过角色组层级实现 **/
|
|
||||||
@Deprecated
|
|
||||||
public List<SaasRoleGroup> listByCategoryCode(List<String> categoryCode) {
|
|
||||||
return lambdaQuery().eq(BaseEntity::getIsDelete, 0L)
|
|
||||||
.in(SaasRoleGroup::getCategoryCode, categoryCode).list();
|
|
||||||
}
|
|
||||||
|
|
||||||
public List<SaasRoleGroup> listByCodes(List<String> codes) {
|
public List<SaasRoleGroup> listByCodes(List<String> codes) {
|
||||||
return lambdaQuery().eq(BaseEntity::getIsDelete, 0L)
|
return lambdaQuery().eq(BaseEntity::getIsDelete, 0L)
|
||||||
.in(SaasRoleGroup::getCode, codes).list();
|
.in(SaasRoleGroup::getCode, codes).list();
|
||||||
|
|||||||
@ -2,7 +2,6 @@ package cn.axzo.tyr.server.repository.dao;
|
|||||||
|
|
||||||
import cn.axzo.basics.common.constant.enums.TableIsDeleteEnum;
|
import cn.axzo.basics.common.constant.enums.TableIsDeleteEnum;
|
||||||
import cn.axzo.karma.client.model.dto.ProjectWorkBaseDTO;
|
import cn.axzo.karma.client.model.dto.ProjectWorkBaseDTO;
|
||||||
import cn.axzo.pokonyan.config.mybatisplus.BaseEntity;
|
|
||||||
import cn.axzo.tyr.client.model.BaseWorkspaceModel;
|
import cn.axzo.tyr.client.model.BaseWorkspaceModel;
|
||||||
import cn.axzo.tyr.client.model.enums.IdentityType;
|
import cn.axzo.tyr.client.model.enums.IdentityType;
|
||||||
import cn.axzo.tyr.client.model.enums.SaasJobTypeEnum;
|
import cn.axzo.tyr.client.model.enums.SaasJobTypeEnum;
|
||||||
@ -32,16 +31,6 @@ public class SaasRoleUserRelationDao extends ServiceImpl<SaasRoleUserRelationMap
|
|||||||
@Autowired
|
@Autowired
|
||||||
private SaasRoleUserRelationMapper saasRoleUserRelationMapper;
|
private SaasRoleUserRelationMapper saasRoleUserRelationMapper;
|
||||||
|
|
||||||
public List<SaasRoleUserRelation> query(Long identityId, Integer identityType, Long workspaceId, Long ouId) {
|
|
||||||
return this.lambdaQuery()
|
|
||||||
.eq(SaasRoleUserRelation::getIdentityId, identityId)
|
|
||||||
.eq(SaasRoleUserRelation::getIdentityType, identityType)
|
|
||||||
.eq(null != workspaceId, SaasRoleUserRelation::getWorkspaceId, workspaceId)
|
|
||||||
.eq(null != ouId, SaasRoleUserRelation::getOuId, ouId)
|
|
||||||
.eq(BaseEntity::getIsDelete, TableIsDeleteEnum.NORMAL.value)
|
|
||||||
.list();
|
|
||||||
}
|
|
||||||
|
|
||||||
public void deleteById(List<Long> ids) {
|
public void deleteById(List<Long> ids) {
|
||||||
if (CollUtil.isEmpty(ids)) {
|
if (CollUtil.isEmpty(ids)) {
|
||||||
return;
|
return;
|
||||||
@ -154,11 +143,6 @@ public class SaasRoleUserRelationDao extends ServiceImpl<SaasRoleUserRelationMap
|
|||||||
|
|
||||||
public void delByIdentityAndWorkspaceIdAndOuId(Long identityId, cn.axzo.basics.profiles.common.enums.IdentityType identityType, Long workspaceId, Long ouId) {
|
public void delByIdentityAndWorkspaceIdAndOuId(Long identityId, cn.axzo.basics.profiles.common.enums.IdentityType identityType, Long workspaceId, Long ouId) {
|
||||||
getBaseMapper().deleteButNotAdminAndNotLeader(workspaceId, ouId, identityId, identityType, null);
|
getBaseMapper().deleteButNotAdminAndNotLeader(workspaceId, ouId, identityId, identityType, null);
|
||||||
// lambdaUpdate().eq(SaasRoleUserRelation::getWorkspaceId, workspaceId)
|
|
||||||
// .eq(SaasRoleUserRelation::getIdentityId, identityId)
|
|
||||||
// .eq(SaasRoleUserRelation::getIdentityType, identityType)
|
|
||||||
// .eq(SaasRoleUserRelation::getOuId, ouId)
|
|
||||||
// .set(SaasRoleUserRelation::getIsDelete, TableIsDeleteEnum.DELETE.value).update();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public List<SaasRoleUserRelation> findBathSuperAdmin(List<ProjectWorkBaseDTO> req) {
|
public List<SaasRoleUserRelation> findBathSuperAdmin(List<ProjectWorkBaseDTO> req) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user