buzhanyi hace 1 año
padre
commit
c8f7d1ed53

+ 5 - 0
purchase-admin/src/main/java/com/ozs/web/controller/plan/MonthlyReconciliationController.java

@@ -67,6 +67,11 @@ public class MonthlyReconciliationController extends BaseController {
         vo.setDeptId(getDeptId());
         vo.setIsAdmin(SysUser.isAdmin(getUserId()));
         vo.setRoleFlay(false);
+        // 添加数据权限
+        List<String> roleKeys = getLoginUser().getUser().getRoles().stream().map(SysRole::getRoleKey).collect(Collectors.toList());
+        if (roleKeys.contains(Constants.PURCHASING_MANAGEMENT)) {
+            vo.setRoleFlay(true);
+        }
         // 分页查询
         IPage<MonthlyReconciliation> page = monthlyReconciliationService.queryPage(vo);
         // 采购服务站名称