|
|
@@ -145,17 +145,17 @@ public class MenuController {
|
|
|
|
|
|
wrapper.selectAs(Department::getName, MenuTreeVo::getDeptName)
|
|
|
.leftJoin(XjrMenuDeptRelation.class, XjrMenuDeptRelation::getMenuId,Menu::getId)
|
|
|
- .leftJoin(Department.class, Department::getId, XjrMenuDeptRelation::getDeptId);
|
|
|
-
|
|
|
- if (StrUtil.isNotEmpty(dto.getDeptIds())) {
|
|
|
- String[] deptIdArray = dto.getDeptIds().split(",");
|
|
|
- List<String> deptIdList = Arrays.asList(deptIdArray);
|
|
|
-
|
|
|
- if (CollectionUtil.isNotEmpty(deptIdList)) {
|
|
|
- wrapper.in(XjrMenuDeptRelation::getDeptId, deptIdList);
|
|
|
- }
|
|
|
- }
|
|
|
- wrapper.orderByAsc(Menu::getSortCode);
|
|
|
+ .leftJoin(Department.class, Department::getId, XjrMenuDeptRelation::getDeptId)
|
|
|
+ .orderByAsc(Menu::getSortCode);
|
|
|
+
|
|
|
+// if (StrUtil.isNotEmpty(dto.getDeptIds())) {
|
|
|
+// String[] deptIdArray = dto.getDeptIds().split(",");
|
|
|
+// List<String> deptIdList = Arrays.asList(deptIdArray);
|
|
|
+//
|
|
|
+// if (CollectionUtil.isNotEmpty(deptIdList)) {
|
|
|
+// wrapper.in(XjrMenuDeptRelation::getDeptId, deptIdList);
|
|
|
+// }
|
|
|
+// }
|
|
|
|
|
|
List<MenuTreeVo> list = menuService.selectJoinList(MenuTreeVo.class, wrapper);
|
|
|
List<MenuTreeVo> treeVoList = TreeUtil.build(list);
|
|
|
@@ -253,6 +253,7 @@ public class MenuController {
|
|
|
menuFormService.remove(Wrappers.<MenuForm>query().lambda().eq(MenuForm::getMenuId, menu.getId()));
|
|
|
menuFormService.saveBatch(formList);
|
|
|
|
|
|
+ //多选
|
|
|
List<XjrMenuDeptRelation> menuDeptRelationsList = new ArrayList<>();
|
|
|
for (AddXjrMenuDeptRelationDto addXjrMenuDeptRelationDto : dto.getMenuDeptRelations()) {
|
|
|
menuDeptRelationsList.add(BeanUtil.toBean(addXjrMenuDeptRelationDto, XjrMenuDeptRelation.class));
|