瀏覽代碼

fix:save 24

jimmyyem 6 月之前
父節點
當前提交
87c2af8892
共有 3 個文件被更改,包括 6 次插入2 次删除
  1. 1 0
      desc/wechat/user.api
  2. 3 1
      internal/logic/User/get_api_user_vip_logic.go
  3. 2 1
      internal/types/types.go

+ 1 - 0
desc/wechat/user.api

@@ -112,6 +112,7 @@ type (
 
 	UserVip {
 		IsVip *bool `json:"isVip,optional"`
+		WechatAccount *string `json:"wechatAccount"`
 	}
 )
 

+ 3 - 1
internal/logic/User/get_api_user_vip_logic.go

@@ -2,6 +2,7 @@ package User
 
 import (
 	"context"
+	"github.com/alibabacloud-go/tea/tea"
 	"github.com/suyuan32/simple-admin-common/msg/errormsg"
 	"wechat-api/ent"
 	"wechat-api/ent/wxcarduser"
@@ -45,7 +46,8 @@ func (l *GetApiUserVipLogic) GetApiUserVip() (*types.UserVipResp, error) {
 			Msg:  errormsg.Success,
 		},
 		Data: types.UserVip{
-			IsVip: &isVip,
+			IsVip:         &isVip,
+			WechatAccount: tea.String("boweniac"),
 		},
 	}, nil
 }

+ 2 - 1
internal/types/types.go

@@ -1617,7 +1617,8 @@ type UserVipResp struct {
 }
 
 type UserVip struct {
-	IsVip *bool `json:"isVip,optional"`
+	IsVip         *bool   `json:"isVip,optional"`
+	WechatAccount *string `json:"wechatAccount"`
 }
 
 // swagger:model WxidReq