Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
Eladmin
Commits
ed7bfa32
Commit
ed7bfa32
authored
May 20, 2020
by
ZhengJie
Browse files
[代码完善](v2.5): v2.5 beta 角色编辑菜单优化
parent
6bb8b9ce
Changes
2
Hide whitespace changes
Inline
Side-by-side
eladmin-system/src/main/java/me/zhengjie/modules/system/rest/DeptController.java
View file @
ed7bfa32
...
@@ -67,9 +67,9 @@ public class DeptController {
...
@@ -67,9 +67,9 @@ public class DeptController {
@Log
(
"查询部门"
)
@Log
(
"查询部门"
)
@ApiOperation
(
"查询部门:根据ID获取同级与上级数据"
)
@ApiOperation
(
"查询部门:根据ID获取同级与上级数据"
)
@
Ge
tMapping
(
"/superior"
)
@
Pos
tMapping
(
"/superior"
)
@PreAuthorize
(
"@el.check('user:list','dept:list')"
)
@PreAuthorize
(
"@el.check('user:list','dept:list')"
)
public
ResponseEntity
<
Object
>
getSuperior
(
@Request
Param
List
<
Long
>
ids
)
{
public
ResponseEntity
<
Object
>
getSuperior
(
@Request
Body
List
<
Long
>
ids
)
{
Set
<
DeptDto
>
deptDtos
=
new
LinkedHashSet
<>();
Set
<
DeptDto
>
deptDtos
=
new
LinkedHashSet
<>();
for
(
Long
id
:
ids
)
{
for
(
Long
id
:
ids
)
{
DeptDto
deptDto
=
deptService
.
findById
(
id
);
DeptDto
deptDto
=
deptService
.
findById
(
id
);
...
...
eladmin-system/src/main/java/me/zhengjie/modules/system/rest/MenuController.java
View file @
ed7bfa32
...
@@ -85,9 +85,9 @@ public class MenuController {
...
@@ -85,9 +85,9 @@ public class MenuController {
@Log
(
"查询菜单"
)
@Log
(
"查询菜单"
)
@ApiOperation
(
"查询菜单:根据ID获取同级与上级数据"
)
@ApiOperation
(
"查询菜单:根据ID获取同级与上级数据"
)
@
Ge
tMapping
(
"/superior"
)
@
Pos
tMapping
(
"/superior"
)
@PreAuthorize
(
"@el.check('menu:list')"
)
@PreAuthorize
(
"@el.check('menu:list')"
)
public
ResponseEntity
<
Object
>
getSuperior
(
@Request
Param
(
required
=
false
)
List
<
Long
>
ids
)
{
public
ResponseEntity
<
Object
>
getSuperior
(
@Request
Body
List
<
Long
>
ids
)
{
Set
<
MenuDto
>
menuDtos
=
new
LinkedHashSet
<>();
Set
<
MenuDto
>
menuDtos
=
new
LinkedHashSet
<>();
if
(
CollectionUtil
.
isNotEmpty
(
ids
)){
if
(
CollectionUtil
.
isNotEmpty
(
ids
)){
for
(
Long
id
:
ids
)
{
for
(
Long
id
:
ids
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment