feature(权限点): 树形查询支持类型查询,参数扩展
This commit is contained in:
parent
109d244510
commit
dc09ced2a9
@ -7,6 +7,7 @@ import com.alibaba.fastjson.annotation.JSONField;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import lombok.Data;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
@ -68,9 +69,6 @@ public class PermissionPointTreeNode implements IBaseTree<PermissionPointTreeNod
|
||||
/** 小程序ID **/
|
||||
private String microAppItemId;
|
||||
|
||||
/** 下级节点 **/
|
||||
private List<PermissionPointTreeNode> children;
|
||||
|
||||
/**
|
||||
* 网关专属字段,所属应用
|
||||
*/
|
||||
@ -81,6 +79,67 @@ public class PermissionPointTreeNode implements IBaseTree<PermissionPointTreeNod
|
||||
*/
|
||||
private String featureUrl;
|
||||
|
||||
/**
|
||||
* 创建人id
|
||||
*/
|
||||
private Long createBy;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
private LocalDateTime createAt;
|
||||
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
private LocalDateTime updateAt;
|
||||
|
||||
/**
|
||||
* 修改人id
|
||||
*/
|
||||
private Long updateBy;
|
||||
|
||||
private String legacyLayout;
|
||||
|
||||
|
||||
/**
|
||||
* 0:查看 1:操作
|
||||
*/
|
||||
private Integer operateType;
|
||||
|
||||
|
||||
/**
|
||||
* 适用单位类型 1:总包 2:建设单位 4:监理单位 8:劳务分包 16:专业分包 32-班组
|
||||
*/
|
||||
private List<Long> fitOuTypeList;
|
||||
|
||||
/**
|
||||
* 适用节点类型 1:部门 2:班组 4:小组
|
||||
*/
|
||||
private List<Long> fitOuNodeTypeList;
|
||||
|
||||
/**
|
||||
* 是否认证 0:无需要认证 1:需要认证
|
||||
*/
|
||||
private Boolean needCert;
|
||||
|
||||
/**
|
||||
* 是否授权 0:无需要授权 1:需要授权
|
||||
*/
|
||||
private Boolean needAuth;
|
||||
|
||||
|
||||
/** 业务编码 **/
|
||||
private String businessNo;
|
||||
|
||||
/**
|
||||
* 父级业务id
|
||||
*/
|
||||
private String parentBusinessNo;
|
||||
|
||||
/** 下级节点 **/
|
||||
private List<PermissionPointTreeNode> children;
|
||||
|
||||
|
||||
@JsonIgnore
|
||||
@Override
|
||||
|
||||
@ -38,4 +38,7 @@ public class PermissionPointTreeQueryReq {
|
||||
* 1-工作台类型 2-工作台
|
||||
* **/
|
||||
private Integer maxLevel;
|
||||
|
||||
/** featureType 层级过滤-过滤掉featureType大于该值的数据 **/
|
||||
private Integer maxFeatureType;
|
||||
}
|
||||
|
||||
@ -159,7 +159,8 @@ public class PermissionPointServiceImpl implements PermissionPointService {
|
||||
workspace2Terminal(request);
|
||||
//查询条件构建
|
||||
LambdaQueryWrapper<SaasFeature> queryWrapper = new LambdaQueryWrapper<SaasFeature>()
|
||||
.in(CollectionUtil.isNotEmpty(request.getTerminalList()), SaasFeature::getTerminal, request.getTerminalList());
|
||||
.in(CollectionUtil.isNotEmpty(request.getTerminalList()), SaasFeature::getTerminal, request.getTerminalList())
|
||||
.le(Objects.nonNull(request.getMaxFeatureType()), SaasFeature::getFeatureType, request.getMaxFeatureType());
|
||||
//查指定节点子级处理条件
|
||||
if (request.getParentId() != null && request.getParentId() != 0) {
|
||||
SaasFeature parent = this.saasFeatureDao.getById(request.getParentId());
|
||||
|
||||
@ -49,6 +49,7 @@ public class PermissionPointTest {
|
||||
//request.setTerminalList(Arrays.asList("NT_CMS_WEB_ENT_ZB"));
|
||||
request.setDelegateType(0);
|
||||
request.setMaxLevel(3);
|
||||
request.setMaxFeatureType(2);
|
||||
ApiResult<List<PermissionPointTreeNode>> result = controller.listTreeNodes(request);
|
||||
System.out.println("---------------");
|
||||
System.out.println(JSON.toJSONString(result, SerializerFeature.DisableCircularReferenceDetect));
|
||||
|
||||
Loading…
Reference in New Issue
Block a user