Bläddra i källkod

fix:未登录用户常用功能数量限制修改

duxin 11 månader sedan
förälder
incheckning
df051a3fa7
3 ändrade filer med 5 tillägg och 2 borttagningar
  1. 1 1
      api/internal/types/types.go
  2. 1 1
      api/userCenter.api
  3. 3 0
      service/workDesktop.go

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

@@ -214,7 +214,7 @@ type WorkDesktopComprehensiveReq struct {
 	MenuMode     string `json:"menuMode,optional"`
 	MenuIds      string `json:"menuIds,optional"`
 	ActionMode   string `path:"actionMode,options=commonlyRenew|commonlyList|menuMode"`
-	NewUserId    string `header:"newUserId"`
+	NewUserId    string `header:"newUserId,optional"`
 	EntId        string `header:"entId,optional"`
 	EntUserId    string `header:"entUserId,optional"`
 	AccountId    string `header:"accountId,optional"`    //账户id

+ 1 - 1
api/userCenter.api

@@ -252,7 +252,7 @@ type (
 		MenuMode     string `json:"menuMode,optional"`
 		MenuIds      string `json:"menuIds,optional"`
 		ActionMode   string `path:"actionMode,options=commonlyRenew|commonlyList|menuMode"`
-		NewUserId    string `header:"newUserId"`
+		NewUserId    string `header:"newUserId,optional"`
 		EntId        string `header:"entId,optional"`
 		EntUserId    string `header:"entUserId,optional"`
 		AccountId    string `header:"accountId,optional"` //账户id

+ 3 - 0
service/workDesktop.go

@@ -21,6 +21,9 @@ import (
 // 工作桌面--常用功能更新
 // 工作桌面--常用功能列表
 func RenewWorkDesktopMenuModeOrCommonly(in *WorkDesktopComprehensiveReq) (r *WorkDesktopComprehensiveResp) {
+	if in.ActionMode != "commonlyList" && in.UserId == "" {
+		return
+	}
 	r = &WorkDesktopComprehensiveResp{}
 	switch in.ActionMode {
 	case "commonlyRenew": //常用功能更新