bug: 政策法规资料导出权限问题

This commit is contained in:
wxyclub
2023-11-29 17:50:46 +08:00
parent ae05c02797
commit e83b5d8ece
@@ -360,8 +360,9 @@ public class SarLawsInformationServiceImpl extends ServiceImpl<SarLawsInformatio
// 查询有权限的资料ID
LambdaQueryWrapper<SarLawsInformationAuth> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(SarLawsInformationAuth::getUserId, userId);
wrapper.eq(SarLawsInformationAuth::getAuthType, "viewableBy");
wrapper.or().eq(SarLawsInformationAuth::getAuthType, "createAndApproveBy");
wrapper.and(each -> each.eq(SarLawsInformationAuth::getAuthType, "viewableBy")
.or().eq(SarLawsInformationAuth::getAuthType, "createAndApproveBy")
.or().eq(SarLawsInformationAuth::getAuthType, "downloadableBy"));
wrapper.select(SarLawsInformationAuth::getLawsInformationId);
List<SarLawsInformationAuth> informationAuthList = authService.list(wrapper);
if (informationAuthList.size() > 0) {