fix:修复查询报告接口用户权限为null问题

This commit is contained in:
2023-05-09 17:21:02 +08:00
parent e5545d76bb
commit ef81234434
@@ -537,6 +537,8 @@ public class IReportServiceImpl extends ServiceImpl<ReportDao, ReportEntity>
}); });
} else { } else {
list.getRecords().forEach(reportVo -> { list.getRecords().forEach(reportVo -> {
//只有用户没有权限的时候才给默认权限
if (reportVo.getPower() == null) {
//其余人员只能预览公开报告(涉密等级:公开(内部公开)、隐私等级:不涉及用户隐私) //其余人员只能预览公开报告(涉密等级:公开(内部公开)、隐私等级:不涉及用户隐私)
if (reportVo.getConfidentialLevel().equals(PUBLIC_REPORT) && if (reportVo.getConfidentialLevel().equals(PUBLIC_REPORT) &&
reportVo.getPrivacyLevel().equals(NO_USER_PRIVACY_INVOLVED)) { reportVo.getPrivacyLevel().equals(NO_USER_PRIVACY_INVOLVED)) {
@@ -544,6 +546,7 @@ public class IReportServiceImpl extends ServiceImpl<ReportDao, ReportEntity>
} else { } else {
reportVo.setPower(NONE); reportVo.setPower(NONE);
} }
}
}); });
} }