Browse Source

权限区域划分

v1_dev_2
超级管理员 3 years ago
parent
commit
2eb177ad1a
  1. 2
      api/base/loginVerify/login.go
  2. 32
      api/version1/jurisdiction/jurisdictionpc/power.go
  3. 10
      api/version1/jurisdiction/jurisdictionpc/type.go
  4. 7
      identification/interceptor/identity.go
  5. 16
      models/modelssystempermission/empower.go
  6. 1
      overall/appConfig.go
  7. 70
      overall/publicmethod/formatOutput.go
  8. 65
      overall/publicmethod/technique.go
  9. 46
      overall/publicmethod/type.go

2
api/base/loginVerify/login.go

@ -336,8 +336,8 @@ func (a *ApiMethod) ScanCodeLoginNotVerify(c *gin.Context) {
myCont["probationperiod"] = userCont.Probationperiod //试用期 myCont["probationperiod"] = userCont.Probationperiod //试用期
myCont["planformaldate"] = userCont.Planformaldate //预计转正日期 myCont["planformaldate"] = userCont.Planformaldate //预计转正日期
myCont["political_outlook"] = userCont.PoliticalOutlook //政治面貌(1:群众;2:无党派;3:台盟会员;4:九三社员;5:致公党员;6:农工党员;7:民进会员;8:民建会员;9:民盟盟员;10:民革会员,11:共青团员;12:预备党员;13:中共党员) myCont["political_outlook"] = userCont.PoliticalOutlook //政治面貌(1:群众;2:无党派;3:台盟会员;4:九三社员;5:致公党员;6:农工党员;7:民进会员;8:民建会员;9:民盟盟员;10:民革会员,11:共青团员;12:预备党员;13:中共党员)
redisClient.HashMsetAdd(redisMyContKey, myCont) redisClient.HashMsetAdd(redisMyContKey, myCont)
// fmt.Printf("redisMyContKey------Login----->%v\n", redisMyContKey)
publicmethod.Result(0, saveData, c) publicmethod.Result(0, saveData, c)
} }

32
api/version1/jurisdiction/jurisdictionpc/power.go

@ -39,12 +39,40 @@ func (a *ApiMethod) EditPower(c *gin.Context) {
publicmethod.Result(1, err, c, "请至少指定一项权限!") publicmethod.Result(1, err, c, "请至少指定一项权限!")
return return
} }
switch receivedValue.Level {
case 2: //本分部
if len(receivedValue.Organization) < 1 {
receivedValue.Organization = append(receivedValue.Organization, receivedValue.OrdId)
ordIdInt, _ := strconv.ParseInt(receivedValue.OrdId, 10, 64)
_, companyId, _, _, _ := publicmethod.GetOrgStructure(ordIdInt)
var sonOrgId []int64
sonOrgId = publicmethod.GetDepartmentSun(companyId, sonOrgId)
if len(sonOrgId) > 0 {
for oi := 0; oi < len(sonOrgId); oi++ {
sonOrgIdStr := strconv.FormatInt(sonOrgId[oi], 10)
if publicmethod.IsInTrue[string](sonOrgIdStr, receivedValue.Organization) == false {
receivedValue.Organization = append(receivedValue.Organization, sonOrgIdStr)
}
}
}
}
case 3:
var orgAry []string
receivedValue.Organization = orgAry
default:
receivedValue.Level = 1
if len(receivedValue.Organization) < 1 {
var orgAry []string
orgAry = append(orgAry, receivedValue.OrdId)
receivedValue.Organization = orgAry
}
}
var empowerCont modelssystempermission.Empower var empowerCont modelssystempermission.Empower
err = empowerCont.GetCont(map[string]interface{}{"`ordid`": receivedValue.OrdId, "`post_id`": receivedValue.PostId, "`system`": receivedValue.SystemName}, "`id`") err = empowerCont.GetCont(map[string]interface{}{"`ordid`": receivedValue.OrdId, "`post_id`": receivedValue.PostId, "`system`": receivedValue.SystemName}, "`id`")
postIdStr := strings.Join(receivedValue.PointId, ",") postIdStr := strings.Join(receivedValue.PointId, ",")
if err == nil { if err == nil {
err = empowerCont.EiteCont(map[string]interface{}{"`id`": empowerCont.Id}, map[string]interface{}{"`state`": 1, "`point_id`": postIdStr, "`time`": time.Now().Unix()}) err = empowerCont.EiteCont(map[string]interface{}{"`id`": empowerCont.Id}, map[string]interface{}{"`state`": 1, "`point_id`": postIdStr, "`time`": time.Now().Unix(), "`level`": receivedValue.Level, "`organization`": strings.Join(receivedValue.Organization, ",")})
} else { } else {
ordIdInt64, _ := strconv.ParseInt(receivedValue.OrdId, 10, 64) ordIdInt64, _ := strconv.ParseInt(receivedValue.OrdId, 10, 64)
empowerCont.OrdId = ordIdInt64 //行政组织"` empowerCont.OrdId = ordIdInt64 //行政组织"`
@ -54,6 +82,8 @@ func (a *ApiMethod) EditPower(c *gin.Context) {
empowerCont.PointId = postIdStr //权限点位"` empowerCont.PointId = postIdStr //权限点位"`
empowerCont.State = 1 //状态(1:启用;2:禁用;3:删除)"` empowerCont.State = 1 //状态(1:启用;2:禁用;3:删除)"`
empowerCont.Time = time.Now().Unix() //创建时间"` empowerCont.Time = time.Now().Unix() //创建时间"`
empowerCont.Level = receivedValue.Level
empowerCont.Organization = strings.Join(receivedValue.Organization, ",")
err = overall.CONSTANT_DB_System_Permission.Create(&empowerCont).Error err = overall.CONSTANT_DB_System_Permission.Create(&empowerCont).Error
} }
if err != nil { if err != nil {

10
api/version1/jurisdiction/jurisdictionpc/type.go

@ -17,10 +17,12 @@ func (a *ApiMethod) Index(c *gin.Context) {
// 添加权限参数 // 添加权限参数
type appPowerStruct struct { type appPowerStruct struct {
OrdId string `json:"ordid"` //岗位 OrdId string `json:"ordid"` //行政组织
PostId string `json:"postid"` //岗位 PostId string `json:"postid"` //岗位
SystemName string `json:"systemname"` //系统识别符 SystemName string `json:"systemname"` //系统识别符
PointId []string `json:"pointid"` //权限点位 PointId []string `json:"pointid"` //权限点位
Level int `json:"level"` //授权范围等级(1:本部门;2:本分部;3:所有)
Organization []string `json:"organization"` //行政组织ID
} }
// 添加应用系统 // 添加应用系统

7
identification/interceptor/identity.go

@ -111,6 +111,12 @@ func AuthenticateUser() gin.HandlerFunc {
// fmt.Printf("myContRedisJson------------>%v\n", string(myContRedisJson)) // fmt.Printf("myContRedisJson------------>%v\n", string(myContRedisJson))
redisClient.HashMsetAdd(redisMyContKey, myContRedis) redisClient.HashMsetAdd(redisMyContKey, myContRedis)
//获取授权信息
powerCont, powerErr := publicmethod.GetPostOfUsEmpowerCont(myCont.AdminOrg, myCont.Position, "kpi")
c.Set(overall.MyContJwtPower, powerCont)
fmt.Printf("redisMyContKey------Login----->%v----->%v\n", powerErr, powerCont)
c.Next() c.Next()
} }
} }
@ -131,6 +137,7 @@ func VerifyUrl() gin.HandlerFunc {
act := c.Request.Method act := c.Request.Method
menuIdAry, menuUrl, err := publicmethod.GetPostPower(context.AdminOrg, context.Position, "kpi") menuIdAry, menuUrl, err := publicmethod.GetPostPower(context.AdminOrg, context.Position, "kpi")
//此功能暂时不开启 //此功能暂时不开启
// if err != nil || len(menuUrl) < 1 || len(menuIdAry) < 1 { // if err != nil || len(menuUrl) < 1 || len(menuIdAry) < 1 {
// response.FailWithDetailed(gin.H{"reload": false, "code": 402}, "对不起!你没有访问此功能的权限!", c) // response.FailWithDetailed(gin.H{"reload": false, "code": 402}, "对不起!你没有访问此功能的权限!", c)

16
models/modelssystempermission/empower.go

@ -7,13 +7,15 @@ import (
// 权限配置 // 权限配置
type Empower struct { type Empower struct {
Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"` Id int64 `json:"id" gorm:"primaryKey;column:id;type:bigint(20) unsigned;not null;comment:Id;index"`
OrdId int64 `json:"ordid" gorm:"column:ordid;type:bigint(20) unsigned;default:0;not null;comment:行政组织"` OrdId int64 `json:"ordid" gorm:"column:ordid;type:bigint(20) unsigned;default:0;not null;comment:行政组织"`
PostId int64 `json:"postid" gorm:"column:post_id;type:bigint(20) unsigned;default:0;not null;comment:岗位ID"` PostId int64 `json:"postid" gorm:"column:post_id;type:bigint(20) unsigned;default:0;not null;comment:岗位ID"`
System string `json:"system" gorm:"column:system;type:varchar(255) ;comment:系统"` System string `json:"system" gorm:"column:system;type:varchar(255) ;comment:系统"`
PointId string `json:"pointid" gorm:"column:point_id;type:longtext;comment:权限点位"` PointId string `json:"pointid" gorm:"column:point_id;type:longtext;comment:权限点位"`
State int `json:"state" gorm:"column:state;type:tinyint(1) unsigned;default:1;not null;comment:状态(1:启用;2:禁用;3:删除)"` State int `json:"state" gorm:"column:state;type:tinyint(1) unsigned;default:1;not null;comment:状态(1:启用;2:禁用;3:删除)"`
Time int64 `json:"time" gorm:"column:time;type:bigint(20) unsigned;default:0;not null;comment:创建时间"` Time int64 `json:"time" gorm:"column:time;type:bigint(20) unsigned;default:0;not null;comment:创建时间"`
Level int `json:"level" gorm:"column:level;type:int(1) unsigned;default:1;not null;comment:授权范围等级(1:本部门;2:本分部;3:所有)"`
Organization string `json:"organization" gorm:"column:organization;type:longtext;comment:行政组织"`
} }
func (Empower *Empower) TableName() string { func (Empower *Empower) TableName() string {

1
overall/appConfig.go

@ -16,6 +16,7 @@ var (
EmployeeStatusOld = []int{11, 12, 13, 14} //用工关系(1:临时工 , 2:编外人员 ;3:实习&实习生;4:试用员工;5:待分配;6:待岗;7:临时调入;8:正式员工;9:长期病假;10:停薪留职;11:退休;12:辞职;13:辞退;14:离职) EmployeeStatusOld = []int{11, 12, 13, 14} //用工关系(1:临时工 , 2:编外人员 ;3:实习&实习生;4:试用员工;5:待分配;6:待岗;7:临时调入;8:正式员工;9:长期病假;10:停薪留职;11:退休;12:辞职;13:辞退;14:离职)
DockingKingdeeUrl = "http://36.134.44.40:18888" DockingKingdeeUrl = "http://36.134.44.40:18888"
MyContJwt = "mycontjwt" MyContJwt = "mycontjwt"
MyContJwtPower = "mycontjwtpower"
) )
// 全局配置 // 全局配置

70
overall/publicmethod/formatOutput.go

@ -53,24 +53,86 @@ func ResultList(code, page, pageSize int, total, count int64, data interface{},
} }
// 登录信息转换 // 登录信息转换
func LoginMyCont(c *gin.Context) (myCont modelshr.ManCont, err error) { func LoginMyCont(c *gin.Context) (myCont AuthenticationPower, err error) {
var myContInfo modelshr.ManCont
context, exi := c.Get(overall.MyContJwt) context, exi := c.Get(overall.MyContJwt)
contextPower, exiPower := c.Get(overall.MyContJwtPower)
if exi != true { if exi != true {
err = errors.New("对不起!你没有该功能的操作权限!1") err = errors.New("对不起!你没有该功能的操作权限!1")
return return
} }
jsonCont, jsonErr := json.Marshal(context) jsonCont, jsonErr := json.Marshal(context)
// fmt.Printf("LoginMyCont--------->%v\n", string(jsonCont)) // fmt.Printf("LoginMyCont--------->%v--------->%v\n", contextPower, exiPower)
if jsonErr != nil { if jsonErr != nil {
err = jsonErr err = jsonErr
return return
} }
jsonUnErr := json.Unmarshal(jsonCont, &myCont) jsonUnErr := json.Unmarshal(jsonCont, &myContInfo)
if jsonUnErr != nil { if jsonUnErr != nil {
err = jsonUnErr err = jsonUnErr
return return
} }
var powerInfo SystemPowerInfo
if exiPower == true {
jsonPowerCont, _ := json.Marshal(contextPower)
json.Unmarshal(jsonPowerCont, &powerInfo)
fmt.Printf("LoginMyCont--------->%v--------->%v\n", powerInfo, string(jsonPowerCont))
}
myCont.Id = myContInfo.Id
myCont.Number = myContInfo.Number //员工工号"`
myCont.Name = myContInfo.Name //姓名"`
myCont.Icon = myContInfo.Icon //头像"`
myCont.HireClass = myContInfo.HireClass //雇佣类型(1:雇佣入职;2:再入职;)"`
myCont.EmpType = myContInfo.EmpType //用工关系(1:临时工 , 2:编外人员 ;3:实习&实习生;4:试用员工;5:待分配;6:待岗;7:临时调入;8:正式员工;9:长期病假;10:停薪留职;11:退休;12:辞职;13:辞退;14:离职)"`
myCont.Company = myContInfo.Company //入职公司"`
myCont.MainDeparment = myContInfo.MainDeparment //主部门"`
myCont.SunMainDeparment = myContInfo.SunMainDeparment //二级主部门"`
myCont.Deparment = myContInfo.Deparment //部门
myCont.AdminOrg = myContInfo.AdminOrg // 所属行政组织"`
myCont.TeamId = myContInfo.TeamId //班组"`
myCont.Position = myContInfo.Position //职位"`
myCont.JobClass = myContInfo.JobClass // 职务分类"`
myCont.JobId = myContInfo.JobId //职务"`
myCont.JobLeve = myContInfo.JobLeve //职务等级"`
myCont.Time = myContInfo.Time //写入时间"`
myCont.EiteTime = myContInfo.EiteTime // 编辑时间"`
myCont.Wechat = myContInfo.Wechat //微信UserId"`
myCont.WorkWechat = myContInfo.WorkWechat //企业微信UserId"`
myCont.State = myContInfo.State //状态(1:启用;2:禁用;3:删除)`
myCont.Key = myContInfo.Key //nkey"`
myCont.IsAdmin = myContInfo.IsAdmin //是否为管理员(1:不是;2:分公司;3:集团管理员;4:超级管`
myCont.Password = myContInfo.Password // 密码"`
myCont.Role = myContInfo.Role // 角色
myCont.Idcardno = myContInfo.Idcardno //t 身份证号"`
myCont.Passportno = myContInfo.Passportno // 护照号码"`
myCont.Globalroaming = myContInfo.Globalroaming // 国际区号"`
myCont.Mobilephone = myContInfo.Mobilephone //手机号码"`
myCont.Email = myContInfo.Email //电子邮件"`
myCont.Gender = myContInfo.Gender //性别(1:男性;2:女性;3:中性)"`
myCont.Birthday = myContInfo.Birthday //birthday"`
myCont.Myfolk = myContInfo.Myfolk //民族"`
myCont.Nativeplace = myContInfo.Nativeplace //籍贯"`
myCont.Idcardstartdate = myContInfo.Idcardstartdate // 身份证有效期开始"`
myCont.Idcardenddate = myContInfo.Idcardenddate //身份证有效期结束"`
myCont.Idcardaddress = myContInfo.Idcardaddress // 身份证地址"`
myCont.IdcardIssued = myContInfo.IdcardIssued // 身份证签发机关"`
myCont.Health = myContInfo.Health //健康状况(1:良好;2:一般;3:较弱,4:有生理缺陷;5:残废)"`
myCont.Maritalstatus = myContInfo.Maritalstatus //婚姻状况(1:未婚;2:已婚;3:丧偶;4:离异)"`
myCont.Internaltelephone = myContInfo.Internaltelephone //i内线电话"`
myCont.Currentresidence = myContInfo.Currentresidence //现居住地址"`
myCont.Constellation = myContInfo.Constellation //星座(1:白羊座;2:金牛座;3:双子座;4:巨蟹座;5:狮子座;6:处女座;7:天枰座;8:天蝎座;9:射手座;10:摩羯座;11:水瓶座;12:双鱼座)"`
myCont.Isdoubleworker = myContInfo.Isdoubleworker //是否双职工(1:是;2:否)"`
myCont.Isveterans = myContInfo.Isveterans //是否为退役军人(1:是;2:否)"`
myCont.Veteransnumber = myContInfo.Veteransnumber //退役证编号"`
myCont.Jobstartdate = myContInfo.Jobstartdate //参加工作日期"`
myCont.Entrydate = myContInfo.Entrydate //入职日期"`
myCont.Probationperiod = myContInfo.Probationperiod //试用期"`
myCont.Planformaldate = myContInfo.Planformaldate //预计转正日期"`
myCont.PoliticalOutlook = myContInfo.PoliticalOutlook //政治面貌(1:群众;2:无党派;3:台盟会员;4:九三社员;5:致公党员;6:农工党员;7:民进会员;8:民建会员;9:民盟盟员;10:民革会员,11:共青团员;12:预备党员;13:中共党员)"`
myCont.Level = powerInfo.Level
myCont.PointIdList = powerInfo.PointIdList
myCont.OrganizationList = powerInfo.OrganizationList
return return
} }

65
overall/publicmethod/technique.go

@ -1087,3 +1087,68 @@ func GetPeopleInPostList(userKey, ordId, postId int64) (peopleList []PostPeople)
// } // }
return return
} }
// 获取岗位权限信息
func GetPostOfUsEmpowerCont(orgId, postId int64, systemName string) (sysPowerCont SystemPowerInfo, err error) {
redisFileKey := fmt.Sprintf("Licence:LoginApi_%v_%v_%v", systemName, orgId, postId)
redisClient := grocerystore.RunRedis(overall.CONSTANT_REDIS3)
userRedisToken, isTrue := redisClient.HashGetAll(redisFileKey)
if isTrue == false {
var systemPowerCont modelssystempermission.Empower
err = systemPowerCont.GetCont(map[string]interface{}{"`ordid`": orgId, "`post_id`": postId, "`system`": systemName})
if err != nil {
return
}
sysPowerCont.Id = systemPowerCont.Id
sysPowerCont.OrdId = systemPowerCont.OrdId //行政组织"`
sysPowerCont.PostId = systemPowerCont.PostId //岗位ID"`
sysPowerCont.System = systemPowerCont.System //系统"`
sysPowerCont.PointId = systemPowerCont.PointId //权限点位"`
sysPowerCont.State = systemPowerCont.State //状态(1:启用;2:禁用;3:删除)"`
sysPowerCont.Time = systemPowerCont.Time //创建时间"`
sysPowerCont.Level = systemPowerCont.Level //授权范围等级(1:本部门;2:本分部;3:所有)"`
sysPowerCont.Organization = systemPowerCont.Organization //行政组织"`
sysPowerCont.PointIdList = strings.Split(systemPowerCont.PointId, ",")
sysPowerCont.OrganizationList = strings.Split(systemPowerCont.Organization, ",")
myContRedis := MapOut[string]()
myContRedis["id"] = systemPowerCont.Id
myContRedis["ordid"] = systemPowerCont.OrdId
myContRedis["postid"] = systemPowerCont.PostId
myContRedis["system"] = systemPowerCont.System
myContRedis["pointid"] = systemPowerCont.PointId
myContRedis["state"] = systemPowerCont.State
myContRedis["time"] = systemPowerCont.Time
myContRedis["level"] = systemPowerCont.Level
myContRedis["organization"] = systemPowerCont.Organization
redisClient.SetRedisTime(10800)
redisClient.HashMsetAdd(redisFileKey, myContRedis)
} else {
idInt, _ := strconv.ParseInt(userRedisToken["id"], 10, 64)
sysPowerCont.Id = idInt
orgIdInt, _ := strconv.ParseInt(userRedisToken["ordid"], 10, 64)
sysPowerCont.OrdId = orgIdInt //行政组织"`
postIdInt, _ := strconv.ParseInt(userRedisToken["postid"], 10, 64)
sysPowerCont.PostId = postIdInt //岗位ID"`
sysPowerCont.System = userRedisToken["system"] //系统"`
sysPowerCont.PointId = userRedisToken["pointid"] //权限点位"`
stateInt, _ := strconv.Atoi(userRedisToken["state"])
sysPowerCont.State = stateInt //状态(1:启用;2:禁用;3:删除)"`
timeInt, _ := strconv.ParseInt(userRedisToken["time"], 10, 64)
sysPowerCont.Time = timeInt //创建时间"`
levelInt, _ := strconv.Atoi(userRedisToken["level"])
sysPowerCont.Level = levelInt //授权范围等级(1:本部门;2:本分部;3:所有)"`
sysPowerCont.Organization = userRedisToken["organization"] //行政组织"`
sysPowerCont.PointIdList = strings.Split(userRedisToken["pointid"], ",")
sysPowerCont.OrganizationList = strings.Split(userRedisToken["organization"], ",")
writeRedisData := MapOut[string]()
for i, v := range userRedisToken {
writeRedisData[i] = v
}
redisClient.SetRedisTime(10800)
redisClient.HashMsetAdd(redisFileKey, writeRedisData)
}
return
}

46
overall/publicmethod/type.go

@ -1,41 +1,46 @@
package publicmethod package publicmethod
//泛型基础变量类型 import (
"key_performance_indicators/models/modelshr"
"key_performance_indicators/models/modelssystempermission"
)
// 泛型基础变量类型
type GenericityVariable interface { type GenericityVariable interface {
int | int8 | int16 | int32 | int64 | float32 | float64 | string int | int8 | int16 | int32 | int64 | float32 | float64 | string
} }
//格式化输出 // 格式化输出
type Reply struct { type Reply struct {
Code int `json:"code"` Code int `json:"code"`
Msg string `json:"msg"` Msg string `json:"msg"`
Data interface{} `json:"data"` Data interface{} `json:"data"`
} }
//翻页信息 // 翻页信息
type PagesTurn struct { type PagesTurn struct {
Page int `json:"page"` Page int `json:"page"`
PageSize int `json:"pagesize"` PageSize int `json:"pagesize"`
} }
//通用ID结构体 // 通用ID结构体
type PublicId struct { type PublicId struct {
Id string `json:"id"` Id string `json:"id"`
} }
//通用name结构体 // 通用name结构体
type PublicName struct { type PublicName struct {
Name string `json:"name"` Name string `json:"name"`
} }
//通用编辑状态结构体 // 通用编辑状态结构体
type PublicState struct { type PublicState struct {
PublicId PublicId
State int `json:"state"` State int `json:"state"`
IsTrue int `json:"istrue"` //1:强制删除;非1:软删除 IsTrue int `json:"istrue"` //1:强制删除;非1:软删除
} }
//通用图片结构体列表 // 通用图片结构体列表
type PubilcImageList struct { type PubilcImageList struct {
Id string `json:"id"` Id string `json:"id"`
Url string `json:"url"` //图片地址 Url string `json:"url"` //图片地址
@ -43,21 +48,21 @@ type PubilcImageList struct {
FileSize string `json:"filesize"` //文档大小 FileSize string `json:"filesize"` //文档大小
} }
//通用图片结构体内容 // 通用图片结构体内容
type PubilcImageCont struct { type PubilcImageCont struct {
PubilcImageList PubilcImageList
Imgpath string `json:"imgpath"` //物理地址 Imgpath string `json:"imgpath"` //物理地址
AscriptionId string `json:"ascriptionid"` //归属 AscriptionId string `json:"ascriptionid"` //归属
} }
//附件格式 // 附件格式
type EnclosureFormat struct { type EnclosureFormat struct {
FileName string `json:"filename"` //附件名称 FileName string `json:"filename"` //附件名称
FilePath string `json:"filepath"` //附件地址 FilePath string `json:"filepath"` //附件地址
FileType int `json:"filetype"` //附件类型 1:图片;2:视频;3:表格;4:word;5:pdf;7:其他文件 FileType int `json:"filetype"` //附件类型 1:图片;2:视频;3:表格;4:word;5:pdf;7:其他文件
} }
//授权输出 // 授权输出
type empowerOut struct { type empowerOut struct {
MenuIdAry []string `json:"menuid"` MenuIdAry []string `json:"menuid"`
MenuUrl []string `json:"menuurl"` MenuUrl []string `json:"menuurl"`
@ -78,7 +83,7 @@ type PowerThree struct {
MenuOperation []MenuContList `json:"menuOperation"` MenuOperation []MenuContList `json:"menuOperation"`
} }
//部门判断列表 // 部门判断列表
type DepartmentIsPower struct { type DepartmentIsPower struct {
PublicId PublicId
PublicName PublicName
@ -89,7 +94,7 @@ type DepartmentIsPower struct {
PowerPeople []DepartSoverePostMan `json:"powerpeople"` PowerPeople []DepartSoverePostMan `json:"powerpeople"`
} }
//获取主权部门的负责人 // 获取主权部门的负责人
type DepartSoverePostMan struct { type DepartSoverePostMan struct {
PublicId PublicId
PublicName PublicName
@ -103,7 +108,7 @@ type PeopleSoverePostMan struct {
PostName string `json:"postname"` PostName string `json:"postname"`
} }
//岗位递归 // 岗位递归
type PositionDigui struct { type PositionDigui struct {
PublicId PublicId
PublicName PublicName
@ -127,3 +132,18 @@ type PostPeople struct {
DutiesName string `json:"dutiesname"` DutiesName string `json:"dutiesname"`
Wechat string `json:"wechat"` Wechat string `json:"wechat"`
} }
// 权限分配详情分解
type SystemPowerInfo struct {
modelssystempermission.Empower
PointIdList []string `json:"point_id_list"`
OrganizationList []string `json:"organization"`
}
// 鉴权个人信息
type AuthenticationPower struct {
modelshr.ManCont
Level int `json:"level"`
PointIdList []string `json:"point_id_list"`
OrganizationList []string `json:"organization"`
}

Loading…
Cancel
Save