|
@@ -83,7 +83,7 @@ public class SysPermissionController {
|
|
LambdaQueryWrapper<SysPermission> query = new LambdaQueryWrapper<SysPermission>();
|
|
LambdaQueryWrapper<SysPermission> query = new LambdaQueryWrapper<SysPermission>();
|
|
query.eq(SysPermission::getDelFlag, CommonConstant.DEL_FLAG_0);
|
|
query.eq(SysPermission::getDelFlag, CommonConstant.DEL_FLAG_0);
|
|
query.orderByAsc(SysPermission::getSortNo);
|
|
query.orderByAsc(SysPermission::getSortNo);
|
|
-
|
|
|
|
|
|
+
|
|
//支持通过菜单名字,模糊查询
|
|
//支持通过菜单名字,模糊查询
|
|
if(oConvertUtils.isNotEmpty(sysPermission.getName())){
|
|
if(oConvertUtils.isNotEmpty(sysPermission.getName())){
|
|
query.like(SysPermission::getName, sysPermission.getName());
|
|
query.like(SysPermission::getName, sysPermission.getName());
|
|
@@ -207,7 +207,7 @@ public class SysPermissionController {
|
|
|
|
|
|
// /**
|
|
// /**
|
|
// * 查询用户拥有的菜单权限和按钮权限(根据用户账号)
|
|
// * 查询用户拥有的菜单权限和按钮权限(根据用户账号)
|
|
-// *
|
|
|
|
|
|
+// *
|
|
// * @return
|
|
// * @return
|
|
// */
|
|
// */
|
|
// @RequestMapping(value = "/queryByUser", method = RequestMethod.GET)
|
|
// @RequestMapping(value = "/queryByUser", method = RequestMethod.GET)
|
|
@@ -243,13 +243,13 @@ public class SysPermissionController {
|
|
return Result.error("请登录系统!");
|
|
return Result.error("请登录系统!");
|
|
}
|
|
}
|
|
List<SysPermission> metaList = sysPermissionService.queryByUser(loginUser.getUsername());
|
|
List<SysPermission> metaList = sysPermissionService.queryByUser(loginUser.getUsername());
|
|
- //添加首页路由
|
|
|
|
- //update-begin-author:taoyan date:20200211 for: TASK #3368 【路由缓存】首页的缓存设置有问题,需要根据后台的路由配置来实现是否缓存
|
|
|
|
- if(!PermissionDataUtil.hasIndexPage(metaList)){
|
|
|
|
- SysPermission indexMenu = sysPermissionService.list(new LambdaQueryWrapper<SysPermission>().eq(SysPermission::getName,"首页")).get(0);
|
|
|
|
- metaList.add(0,indexMenu);
|
|
|
|
- }
|
|
|
|
- //update-end-author:taoyan date:20200211 for: TASK #3368 【路由缓存】首页的缓存设置有问题,需要根据后台的路由配置来实现是否缓存
|
|
|
|
|
|
+// //添加首页路由
|
|
|
|
+// //update-begin-author:taoyan date:20200211 for: TASK #3368 【路由缓存】首页的缓存设置有问题,需要根据后台的路由配置来实现是否缓存
|
|
|
|
+// if(!PermissionDataUtil.hasIndexPage(metaList)){
|
|
|
|
+// SysPermission indexMenu = sysPermissionService.list(new LambdaQueryWrapper<SysPermission>().eq(SysPermission::getName,"首页")).get(0);
|
|
|
|
+// metaList.add(0,indexMenu);
|
|
|
|
+// }
|
|
|
|
+// //update-end-author:taoyan date:20200211 for: TASK #3368 【路由缓存】首页的缓存设置有问题,需要根据后台的路由配置来实现是否缓存
|
|
|
|
|
|
//update-begin--Author:zyf Date:20220425 for:自定义首页地址 LOWCOD-1578
|
|
//update-begin--Author:zyf Date:20220425 for:自定义首页地址 LOWCOD-1578
|
|
String version = request.getHeader(CommonConstant.VERSION);
|
|
String version = request.getHeader(CommonConstant.VERSION);
|
|
@@ -273,7 +273,7 @@ public class SysPermissionController {
|
|
}
|
|
}
|
|
//update-end---author:liusq ---date:2022-06-29 for:设置自定义首页地址和组件-----------
|
|
//update-end---author:liusq ---date:2022-06-29 for:设置自定义首页地址和组件-----------
|
|
}
|
|
}
|
|
-
|
|
|
|
|
|
+
|
|
JSONObject json = new JSONObject();
|
|
JSONObject json = new JSONObject();
|
|
JSONArray menujsonArray = new JSONArray();
|
|
JSONArray menujsonArray = new JSONArray();
|
|
this.getPermissionJsonArray(menujsonArray, metaList, null);
|
|
this.getPermissionJsonArray(menujsonArray, metaList, null);
|
|
@@ -299,7 +299,7 @@ public class SysPermissionController {
|
|
json.put("sysSafeMode", jeecgBaseConfig.getSafeMode());
|
|
json.put("sysSafeMode", jeecgBaseConfig.getSafeMode());
|
|
result.setResult(json);
|
|
result.setResult(json);
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
- result.error500("查询失败:" + e.getMessage());
|
|
|
|
|
|
+ result.error500("查询失败:" + e.getMessage());
|
|
log.error(e.getMessage(), e);
|
|
log.error(e.getMessage(), e);
|
|
}
|
|
}
|
|
return result;
|
|
return result;
|