日志权限控制:仅管理员支持查询全部;普通用户仅支持查询有权限的 jobGroup

master
xuxueli 6 years ago
parent 211abb985b
commit b202af1334
  1. 2
      xxl-job-admin/src/main/java/com/xxl/job/admin/controller/JobInfoController.java

@ -86,7 +86,7 @@ public class JobInfoController {
public static void validPermission(HttpServletRequest request, int jobGroup) {
XxlJobUser loginUser = (XxlJobUser) request.getAttribute(LoginService.LOGIN_IDENTITY_KEY);
if (!loginUser.validPermission(jobGroup)) {
throw new RuntimeException(I18nUtil.getString("system_permission_limit"));
throw new RuntimeException(I18nUtil.getString("system_permission_limit") + "[username="+ loginUser.getUsername() +"]");
}
}

Loading…
Cancel
Save