Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart_gov_platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
smart_gov_platform
Commits
2a1a0565
Commit
2a1a0565
authored
Aug 01, 2022
by
廖旭伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
获取角色授权菜单bug修改
parent
878d3322
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
16 deletions
+10
-16
portal-manager/doc/api.md
portal-manager/doc/api.md
+2
-13
portal-manager/src/main/java/com/mortals/xhx/module/role/web/RoleController.java
.../java/com/mortals/xhx/module/role/web/RoleController.java
+7
-2
portal-manager/src/main/resources/sqlmap/module/menu/menuExt.xml
...manager/src/main/resources/sqlmap/module/menu/menuExt.xml
+1
-1
No files found.
portal-manager/doc/api.md
View file @
2a1a0565
...
...
@@ -954,14 +954,13 @@ data|object|数据对象
  
roleCode|String|角色编码
  
roleSort|Integer|角色排序字段
  
remark|String|备注
  
roleType|Integer|角色状态(0.停用,1.启用)
  
menuIdList|Arrays|菜单ID列表,值为long
  
createTime|Date|创建时间
  
createUserId|Long|创建用户
  
createUserName|String|创建用户名称
dict|object|字典对象
 
roleType|object|字典属性对象,详见附录
 
roleType
|object|字典属性对象,详见附录
 
status
|object|字典属性对象,详见附录
**响应消息样例:**
```
...
...
@@ -1003,15 +1002,13 @@ data|object|数据对象
 
name|String|角色名称
 
roleCode|String|角色编码
 
roleSort|Integer|角色排序字段
 
roleType|Integer|角色类型(0.系统内置角色,1.默认系统角色,2.普通角色)
 
remark|String|备注
 
roleType|Integer|角色状态(0.停用,1.启用)
 
createTime|Date|创建时间
 
createUserId|Long|创建用户
 
createUserName|String|创建用户名称
dict|object|字典对象
 
roleType|object|字典属性对象,详见附录
 
roleType
|object|字典属性对象,详见附录
 
status
|object|字典属性对象,详见附录
**响应消息样例:**
```
...
...
@@ -1022,9 +1019,7 @@ dict|object|字典对象
"name":"c9szsk",
"roleCode":"c2f41g",
"roleSort":2788,
"roleType":541,
"remark":"tym2dx",
"roleType":3737,
"createTime":"2022-06-02",
"createUserId":5091,
"createUserName":"zx9ud1"
...
...
@@ -1049,9 +1044,7 @@ dict|object|字典对象
name|String|是|角色名称
roleCode|String|是|角色编码
roleSort|Integer|是|角色排序字段
roleType|Integer|是|角色类型(0.系统内置角色,1.默认系统角色,2.普通角色)
remark|String|是|备注
roleType|Integer|是|角色状态(0.停用,1.启用)
createUserName|String|是|创建用户名称
**请求样例:**
...
...
@@ -1060,9 +1053,7 @@ createUserName|String|是|创建用户名称
"name":"i8scn3",
"roleCode":"nthtg2",
"roleSort":3063,
"roleType":6039,
"remark":"32xaq6",
"roleType":3352,
"createUserName":"ztwqjn"
}
...
...
@@ -1080,9 +1071,7 @@ data|object|数据对象
  
name|String|角色名称
  
roleCode|String|角色编码
  
roleSort|Integer|角色排序字段
  
roleType|Integer|角色类型(0.系统内置角色,1.默认系统角色,2.普通角色)
  
remark|String|备注
  
roleType|Integer|角色状态(0.停用,1.启用)
  
createTime|Date|创建时间
  
createUserId|Long|创建用户
  
createUserName|String|创建用户名称
...
...
portal-manager/src/main/java/com/mortals/xhx/module/role/web/RoleController.java
View file @
2a1a0565
package
com.mortals.xhx.module.role.web
;
import
com.mortals.framework.exception.AppException
;
import
com.mortals.framework.web.BaseCRUDJsonBodyMappingController
;
import
com.mortals.xhx.module.param.service.ParamService
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -51,9 +52,13 @@ public class RoleController extends BaseCRUDJsonBodyMappingController<RoleServic
@Override
protected
void
init
(
Map
<
String
,
Object
>
model
,
Context
context
)
{
this
.
addDict
(
model
,
"roleType"
,
paramService
.
getParamBySecondOrganize
(
"Role"
,
"roleType"
));
//
this.addDict(model, "roleType", paramService.getParamBySecondOrganize("Role", "roleType"));
super
.
init
(
model
,
context
);
}
@Override
protected
void
saveBefore
(
RoleEntity
entity
,
Map
<
String
,
Object
>
model
,
Context
context
)
throws
AppException
{
entity
.
setRoleType
(
1
);
entity
.
setStatus
(
1
);
}
}
\ No newline at end of file
portal-manager/src/main/resources/sqlmap/module/menu/menuExt.xml
View file @
2a1a0565
...
...
@@ -20,7 +20,7 @@
left join mortals_xhx_role_user ur on rm.roleId = ur.roleId
left join mortals_xhx_role ro on ur.roleId = ro.id
left join mortals_xhx_user u on ur.userId = u.id
where u.id = #{condition.userId} and a.menuType in ('0','1','2') and a.status = 1
AND ro.status = 1
where u.id = #{condition.userId} and a.menuType in ('0','1','2') and a.status = 1
order by a.parentId, a.orderId
</select>
...
...
Write
Preview
Markdown
is supported
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