Commit 48b7e7d0 authored by 黄智's avatar 黄智

用户详情调整

parent b08e5d7c
...@@ -41,6 +41,7 @@ type OrgUserDetail struct { ...@@ -41,6 +41,7 @@ type OrgUserDetail struct {
Phone string `json:"phone" xorm:"phone"` // 联系人电话 Phone string `json:"phone" xorm:"phone"` // 联系人电话
SystemAccount string `json:"system_account" xorm:"system_account"` // 系统账号 SystemAccount string `json:"system_account" xorm:"system_account"` // 系统账号
SystemRole []string `json:"system_role" xorm:"-"` // 系统角色id SystemRole []string `json:"system_role" xorm:"-"` // 系统角色id
SystemRoleName []string `json:"system_role_name" xorm:"-"` // 系统角色名称
Organization string `json:"organization" xorm:"organization"` // 所属组织 Organization string `json:"organization" xorm:"organization"` // 所属组织
OrganizationId string `json:"organization_id"` // 所属组织 OrganizationId string `json:"organization_id"` // 所属组织
CreatedBy int `json:"created_by"` // 创建者 CreatedBy int `json:"created_by"` // 创建者
......
...@@ -17,8 +17,8 @@ func InitAccessRuleRouter(e *gin.Engine) { ...@@ -17,8 +17,8 @@ func InitAccessRuleRouter(e *gin.Engine) {
rule.PUT("updateAccessRule", controller.UpdateAccessRule, header.AddLogMiddleware("访问规则管理", "/updateAccessRule", constant.OpTypeIntMap[constant.Edit])) // 编辑访问规则 rule.PUT("updateAccessRule", controller.UpdateAccessRule, header.AddLogMiddleware("访问规则管理", "/updateAccessRule", constant.OpTypeIntMap[constant.Edit])) // 编辑访问规则
rule.DELETE("delAccessRule", controller.DelAccessRule, header.AddLogMiddleware("访问规则管理", "/delAccessRule", constant.OpTypeIntMap[constant.AllDelete])) // 删除访问规则 rule.DELETE("delAccessRule", controller.DelAccessRule, header.AddLogMiddleware("访问规则管理", "/delAccessRule", constant.OpTypeIntMap[constant.AllDelete])) // 删除访问规则
rule.GET("listAccessRule", controller.ListAccessRule, header.AddLogMiddleware("访问规则管理", "/listAccessRule", constant.OpTypeIntMap[constant.Find])) // 查询访问规则列表 rule.GET("listAccessRule", controller.ListAccessRule, header.AddLogMiddleware("访问规则管理", "/listAccessRule", constant.OpTypeIntMap[constant.Find])) // 查询访问规则列表
rule.GET("listRuleUser", controller.ListRuleUser) // 查询用户详情列表 rule.GET("listRuleUser", controller.ListRuleUser) // 查询用户详情列表
rule.PUT("updateState", controller.UpdateState) // 修改规则状态 rule.PUT("updateState", controller.UpdateState) // 修改规则状态
} }
} }
...@@ -59,6 +59,7 @@ func (o *User) OrgUserDetail(id int) (interface{}, error) { ...@@ -59,6 +59,7 @@ func (o *User) OrgUserDetail(id int) (interface{}, error) {
} }
for _, v := range systemUserRoles { for _, v := range systemUserRoles {
result.SystemRole = append(result.SystemRole, v.RoleId) result.SystemRole = append(result.SystemRole, v.RoleId)
result.SystemRoleName = append(result.SystemRoleName, v.RoleName)
} }
return result, nil return result, nil
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment