Commit bee6d12e authored by linruibiao's avatar linruibiao

接口编写

parent bbff882f
......@@ -235,23 +235,23 @@ public class VariableServiceImpl implements VariableService {
Map<String, String> detach = result.detach();
String officeIds = detach.get("deptIds");
String roleIds = detach.get("roleIds");
if (flag) {
if (CollectionUtils.isNotEmpty(departments)) {
if (departments.stream().map(CustomPermissionDTO::getBizId).anyMatch(officeIds::contains)) {
flag = false;
}
if (CollectionUtils.isNotEmpty(departments)) {
if (departments.stream().map(CustomPermissionDTO::getBizId).anyMatch(officeIds::contains)) {
flag = false;
}
}
if (flag) {
if (CollectionUtils.isNotEmpty(positions)) {
if (positions.stream().map(CustomPermissionDTO::getBizId).anyMatch(roleIds::contains)) {
flag = false;
}
if (CollectionUtils.isNotEmpty(positions)) {
if (positions.stream().map(CustomPermissionDTO::getBizId).anyMatch(roleIds::contains)) {
flag = false;
}
}
if (flag) {
throw new SysException("没有访问权限");
}
}
if (!flag) {
throw new SysException("您没有操作权限");
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment