瀏覽代碼

feat:配置文件备注

wangshan 3 年之前
父節點
當前提交
c5a9f1cefb
共有 4 個文件被更改,包括 14 次插入14 次删除
  1. 3 3
      api/internal/types/types.go
  2. 3 3
      api/userCenter.api
  3. 6 6
      rpc/etc/usercenter.yaml
  4. 2 2
      rpc/internal/logic/workdesktopmenuinfologic.go

+ 3 - 3
api/internal/types/types.go

@@ -221,7 +221,7 @@ type UserDelReq struct {
 }
 
 type WorkDesktopMenuInfoReq struct {
-	Platform  string `json:"platform,default=PC"`
+	Platform  string `json:"platform,default=PC,options=PC|WX|APP"`
 	UserId    string `header:"userId"`
 	AppId     string `header:"appId"`
 	Phone     string `header:"phone,optional"`
@@ -229,7 +229,7 @@ type WorkDesktopMenuInfoReq struct {
 }
 
 type WorkDesktopComprehensiveReq struct {
-	Platform   string `json:"platform,default=PC"`
+	Platform   string `json:"platform,default=PC,options=PC|WX|APP"`
 	UserId     string `header:"userId"`
 	AppId      string `header:"appId"`
 	Phone      string `header:"phone,optional"`
@@ -246,7 +246,7 @@ type CommonResp struct {
 }
 
 type WorkDesktopClearUserInfo struct {
-	Platform  string `json:"platform,default=PC"`
+	Platform  string `json:"platform,default=PC,options=PC|WX|APP"`
 	UserId    string `header:"userId"`
 	AppId     string `header:"appId"`
 	UserIds   string `json:"userIds,optional"`

+ 3 - 3
api/userCenter.api

@@ -235,7 +235,7 @@ type (
 
 	//工作桌面 -- 菜单
 	WorkDesktopMenuInfoReq {
-		Platform  string `json:"platform,default=PC"`
+		Platform  string `json:"platform,default=PC,options=PC|WX|APP"`
 		UserId    string `header:"userId"`
 		AppId     string `header:"appId"`
 		Phone     string `header:"phone,optional"`
@@ -244,7 +244,7 @@ type (
 	//工作桌面-- 菜单模式:全部/可用选择记录
 	//工作桌面--常用功能更新
 	WorkDesktopComprehensiveReq {
-		Platform   string `json:"platform,default=PC"`
+		Platform   string `json:"platform,default=PC,options=PC|WX|APP"`
 		UserId     string `header:"userId"`
 		AppId      string `header:"appId"`
 		Phone      string `header:"phone,optional"`
@@ -261,7 +261,7 @@ type (
 	}
 	//工作桌面清用户内存信息
 	WorkDesktopClearUserInfo {
-		Platform  string `json:"platform,default=PC"`
+		Platform  string `json:"platform,default=PC,options=PC|WX|APP"`
 		UserId    string `header:"userId"`
 		AppId     string `header:"appId"`
 		UserIds   string `json:"userIds,optional"`

+ 6 - 6
rpc/etc/usercenter.yaml

@@ -41,19 +41,19 @@ DoMain: https://jybx-webtest.jydev.jianyu360.com
 Timeout: 5000
 RedisAddrees:
   - newother=192.168.3.206:1712
-RedisOutTime: 300
-InternalTime: 7200
+RedisOutTime: 300 #工作桌面redis缓存时间
+InternalTime: 7200 #用户权限 redis 缓存时间
 Mongo:
   Main:
     dbName: qfw
     size: 50
     address: 192.168.3.206:27080
-BigMemberOff: false
-CommonlySize: 10
-ManagerUserIds: 
+BigMemberOff: false #大会员权益表是否开放给其他用户
+CommonlySize: 8 #常用功能数量
+ManagerUserIds: #可清除用户工作菜单缓存的管理员id
   - 5f51d194b44a4a76fe4cf342
   - 62e09d13df1f161cf87b1153
-UserRolePower:
+UserRolePower: #需要初始化的用户角色
   - 大会员
   - 商机管理
   - 超级订阅

+ 2 - 2
rpc/internal/logic/workdesktopmenuinfologic.go

@@ -41,8 +41,8 @@ func (l *WorkDesktopMenuInfoLogic) WorkDesktopMenuInfo(in *pb.WorkDesktopMenuInf
 	)
 	//菜单树
 	in.BigMemberOff = config.ConfigJson.BigMemberOff //大会员权限开关
-	in.RedisOutTime = config.ConfigJson.RedisOutTime //用户权限 redis 缓存时间
-	in.InternalTime = config.ConfigJson.InternalTime //常用功能 功能设置数量限制
+	in.RedisOutTime = config.ConfigJson.RedisOutTime //用户菜单 redis 缓存时间
+	in.InternalTime = config.ConfigJson.InternalTime //用户权限 redis 缓存时间
 	menuList, err := service.GetWordDesktopMenuTree(in)
 	//菜单模式
 	menuMode, err = service.GetWorkDesktopMenuMode(in)