Compare commits

...

5 Commits

Author SHA1 Message Date
wangliwen 5a796ec8ff Merge branch 'master' into docker_package 2022-12-16 15:09:40 +08:00
wangliwen 95b17b089b Merge branch 'dev' 2022-12-16 15:09:33 +08:00
wangliwen 5db160ca18 ... 2022-12-16 15:09:26 +08:00
wangliwen 1a4505cefc Merge branch 'dev' 2022-12-16 15:07:49 +08:00
wangliwen 9769701093 ... 2022-12-16 15:07:42 +08:00
2 changed files with 2 additions and 2 deletions

View File

@ -151,7 +151,7 @@ public class ResourceController {
}) })
public Result<PageData<ResourceDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params) { public Result<PageData<ResourceDTO>> page(@ApiIgnore @RequestParam Map<String, Object> params) {
// 2022.12.16 后台过滤只出所属区域资源 // 2022.12.16 后台过滤只出所属区域资源
Boolean region = params.containsKey("region") ? (Boolean) params.get("region") : false; // 是否需要过滤只出用户所属区域资源 Boolean region = params.containsKey("region") ? Boolean.parseBoolean(params.get("region").toString()) : false; // 是否需要过滤只出用户所属区域资源
while (region) { while (region) {
List<Long> deptIds = new ArrayList<>(); List<Long> deptIds = new ArrayList<>();
UserDetail user = SecurityUser.getUser(); // 当前用户 UserDetail user = SecurityUser.getUser(); // 当前用户

View File

@ -529,7 +529,7 @@ public class ResourceServiceImpl extends CrudServiceImpl<ResourceDao, ResourceEn
Integer pageNum = jsonObject.getInteger("pageNum"); Integer pageNum = jsonObject.getInteger("pageNum");
Integer pageSize = jsonObject.getInteger("pageSize"); Integer pageSize = jsonObject.getInteger("pageSize");
// 2022.12.16 后台过滤只出所属区域资源 // 2022.12.16 后台过滤只出所属区域资源
Boolean region = jsonObject.containsKey("region") ? jsonObject.getBooleanValue("region") : false; // 是否需要过滤只出用户所属区域资源 Boolean region = jsonObject.containsKey("region") ? Boolean.parseBoolean(jsonObject.getString("region")) : false; // 是否需要过滤只出用户所属区域资源
while (region) { while (region) {
UserDetail user = SecurityUser.getUser(); // 当前用户 UserDetail user = SecurityUser.getUser(); // 当前用户
if (SuperAdminEnum.YES.value() != user.getSuperAdmin()) { // 非超级管理员 if (SuperAdminEnum.YES.value() != user.getSuperAdmin()) { // 非超级管理员