@@ -26,6 +26,7 @@ import ( | |||
"github.com/olivere/elastic/v7" | |||
"github.com/syyongx/php2go" | |||
"github.com/tidwall/gjson" | |||
"strconv" | |||
"strings" | |||
"time" | |||
) | |||
@@ -415,6 +416,11 @@ func ParentInfo(c *gin.Context) { | |||
if user.CustomInviteCode != "" { | |||
code = user.CustomInviteCode | |||
} | |||
imUser, err1 := svc.GetImUser(0, user.Phone) | |||
if err1 != nil { | |||
e.OutErr(c, e.ERR, err1.Error()) | |||
return | |||
} | |||
res := md.ParentInfo{ | |||
Nickname: user.Nickname, | |||
LevelName: level.LevelName, | |||
@@ -423,6 +429,7 @@ func ParentInfo(c *gin.Context) { | |||
Id: utils.Int64ToStr(user.Id), | |||
Phone: user.Phone, | |||
WechatAccount: user.WechatAccount, | |||
ImUid: strconv.FormatInt(imUser.UserId, 10), | |||
} | |||
e.OutSuc(c, res, nil) | |||
return | |||
@@ -72,4 +72,5 @@ type ParentInfo struct { | |||
Id string `json:"id" example:"个人ID号"` | |||
Phone string `json:"phone" example:"手机号"` | |||
WechatAccount string `json:"wechat_account" example:"微信号"` | |||
ImUid string `json:"im_uid" example:"im_uid"` | |||
} |
@@ -4427,6 +4427,68 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd": { | |||
"type": "object", | |||
"properties": { | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"im_data": { | |||
"type": "string" | |||
}, | |||
"im_uid": { | |||
"type": "integer" | |||
}, | |||
"ord_no": { | |||
"type": "string" | |||
}, | |||
"received_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"received_times": { | |||
"type": "string" | |||
}, | |||
"received_user_amount": { | |||
"type": "string" | |||
}, | |||
"received_user_ids": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_amount": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_type": { | |||
"type": "integer" | |||
}, | |||
"state": { | |||
"type": "integer" | |||
}, | |||
"uid": { | |||
"type": "integer" | |||
}, | |||
"update_time": { | |||
"type": "string" | |||
}, | |||
"wait_draw_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"wait_draw_user_ids": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"comm.AccessRecordsReq": { | |||
"type": "object", | |||
"properties": { | |||
@@ -5986,6 +6048,10 @@ const docTemplate = `{ | |||
"now_team_user": { | |||
"description": "团队人数", | |||
"type": "integer" | |||
}, | |||
"real_name_num": { | |||
"description": "团队实名人数", | |||
"type": "integer" | |||
} | |||
} | |||
}, | |||
@@ -6072,6 +6138,10 @@ const docTemplate = `{ | |||
"type": "string", | |||
"example": "个人ID号" | |||
}, | |||
"im_uid": { | |||
"type": "string", | |||
"example": "im_uid" | |||
}, | |||
"invite_code": { | |||
"type": "string", | |||
"example": "邀请码" | |||
@@ -6282,7 +6352,7 @@ const docTemplate = `{ | |||
"description": "红包详情信息", | |||
"allOf": [ | |||
{ | |||
"$ref": "#/definitions/model.ImSendRedPackageOrd" | |||
"$ref": "#/definitions/code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd" | |||
} | |||
] | |||
}, | |||
@@ -7041,68 +7111,6 @@ const docTemplate = `{ | |||
} | |||
} | |||
}, | |||
"model.ImSendRedPackageOrd": { | |||
"type": "object", | |||
"properties": { | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"im_data": { | |||
"type": "string" | |||
}, | |||
"im_uid": { | |||
"type": "integer" | |||
}, | |||
"ord_no": { | |||
"type": "string" | |||
}, | |||
"received_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"received_times": { | |||
"type": "string" | |||
}, | |||
"received_user_amount": { | |||
"type": "string" | |||
}, | |||
"received_user_ids": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_amount": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_type": { | |||
"type": "integer" | |||
}, | |||
"state": { | |||
"type": "integer" | |||
}, | |||
"uid": { | |||
"type": "integer" | |||
}, | |||
"update_time": { | |||
"type": "string" | |||
}, | |||
"wait_draw_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"wait_draw_user_ids": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"pb.SendRedPacketResp": { | |||
"type": "object", | |||
"properties": { | |||
@@ -4421,6 +4421,68 @@ | |||
} | |||
} | |||
}, | |||
"code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd": { | |||
"type": "object", | |||
"properties": { | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"im_data": { | |||
"type": "string" | |||
}, | |||
"im_uid": { | |||
"type": "integer" | |||
}, | |||
"ord_no": { | |||
"type": "string" | |||
}, | |||
"received_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"received_times": { | |||
"type": "string" | |||
}, | |||
"received_user_amount": { | |||
"type": "string" | |||
}, | |||
"received_user_ids": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_amount": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_type": { | |||
"type": "integer" | |||
}, | |||
"state": { | |||
"type": "integer" | |||
}, | |||
"uid": { | |||
"type": "integer" | |||
}, | |||
"update_time": { | |||
"type": "string" | |||
}, | |||
"wait_draw_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"wait_draw_user_ids": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"comm.AccessRecordsReq": { | |||
"type": "object", | |||
"properties": { | |||
@@ -5980,6 +6042,10 @@ | |||
"now_team_user": { | |||
"description": "团队人数", | |||
"type": "integer" | |||
}, | |||
"real_name_num": { | |||
"description": "团队实名人数", | |||
"type": "integer" | |||
} | |||
} | |||
}, | |||
@@ -6066,6 +6132,10 @@ | |||
"type": "string", | |||
"example": "个人ID号" | |||
}, | |||
"im_uid": { | |||
"type": "string", | |||
"example": "im_uid" | |||
}, | |||
"invite_code": { | |||
"type": "string", | |||
"example": "邀请码" | |||
@@ -6276,7 +6346,7 @@ | |||
"description": "红包详情信息", | |||
"allOf": [ | |||
{ | |||
"$ref": "#/definitions/model.ImSendRedPackageOrd" | |||
"$ref": "#/definitions/code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd" | |||
} | |||
] | |||
}, | |||
@@ -7035,68 +7105,6 @@ | |||
} | |||
} | |||
}, | |||
"model.ImSendRedPackageOrd": { | |||
"type": "object", | |||
"properties": { | |||
"amount": { | |||
"type": "string" | |||
}, | |||
"create_time": { | |||
"type": "string" | |||
}, | |||
"id": { | |||
"type": "integer" | |||
}, | |||
"im_data": { | |||
"type": "string" | |||
}, | |||
"im_uid": { | |||
"type": "integer" | |||
}, | |||
"ord_no": { | |||
"type": "string" | |||
}, | |||
"received_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"received_times": { | |||
"type": "string" | |||
}, | |||
"received_user_amount": { | |||
"type": "string" | |||
}, | |||
"received_user_ids": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_amount": { | |||
"type": "string" | |||
}, | |||
"red_packet_balance_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_nums": { | |||
"type": "integer" | |||
}, | |||
"red_packet_type": { | |||
"type": "integer" | |||
}, | |||
"state": { | |||
"type": "integer" | |||
}, | |||
"uid": { | |||
"type": "integer" | |||
}, | |||
"update_time": { | |||
"type": "string" | |||
}, | |||
"wait_draw_im_user_ids": { | |||
"type": "string" | |||
}, | |||
"wait_draw_user_ids": { | |||
"type": "string" | |||
} | |||
} | |||
}, | |||
"pb.SendRedPacketResp": { | |||
"type": "object", | |||
"properties": { | |||
@@ -12,6 +12,47 @@ definitions: | |||
description: 总数据量 | |||
type: integer | |||
type: object | |||
code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd: | |||
properties: | |||
amount: | |||
type: string | |||
create_time: | |||
type: string | |||
id: | |||
type: integer | |||
im_data: | |||
type: string | |||
im_uid: | |||
type: integer | |||
ord_no: | |||
type: string | |||
received_im_user_ids: | |||
type: string | |||
received_times: | |||
type: string | |||
received_user_amount: | |||
type: string | |||
received_user_ids: | |||
type: string | |||
red_packet_balance_amount: | |||
type: string | |||
red_packet_balance_nums: | |||
type: integer | |||
red_packet_nums: | |||
type: integer | |||
red_packet_type: | |||
type: integer | |||
state: | |||
type: integer | |||
uid: | |||
type: integer | |||
update_time: | |||
type: string | |||
wait_draw_im_user_ids: | |||
type: string | |||
wait_draw_user_ids: | |||
type: string | |||
type: object | |||
comm.AccessRecordsReq: | |||
properties: | |||
index: | |||
@@ -1101,6 +1142,9 @@ definitions: | |||
now_team_user: | |||
description: 团队人数 | |||
type: integer | |||
real_name_num: | |||
description: 团队实名人数 | |||
type: integer | |||
type: object | |||
md.MyFansUserListResp: | |||
properties: | |||
@@ -1160,6 +1204,9 @@ definitions: | |||
id: | |||
example: 个人ID号 | |||
type: string | |||
im_uid: | |||
example: im_uid | |||
type: string | |||
invite_code: | |||
example: 邀请码 | |||
type: string | |||
@@ -1306,7 +1353,7 @@ definitions: | |||
properties: | |||
detail: | |||
allOf: | |||
- $ref: '#/definitions/model.ImSendRedPackageOrd' | |||
- $ref: '#/definitions/code_fnuoos_com_EggPlanet_egg_models_git_src_model.ImSendRedPackageOrd' | |||
description: 红包详情信息 | |||
list: | |||
description: 领取红包用户列表 | |||
@@ -1828,47 +1875,6 @@ definitions: | |||
description: 余额 | |||
type: string | |||
type: object | |||
model.ImSendRedPackageOrd: | |||
properties: | |||
amount: | |||
type: string | |||
create_time: | |||
type: string | |||
id: | |||
type: integer | |||
im_data: | |||
type: string | |||
im_uid: | |||
type: integer | |||
ord_no: | |||
type: string | |||
received_im_user_ids: | |||
type: string | |||
received_times: | |||
type: string | |||
received_user_amount: | |||
type: string | |||
received_user_ids: | |||
type: string | |||
red_packet_balance_amount: | |||
type: string | |||
red_packet_balance_nums: | |||
type: integer | |||
red_packet_nums: | |||
type: integer | |||
red_packet_type: | |||
type: integer | |||
state: | |||
type: integer | |||
uid: | |||
type: integer | |||
update_time: | |||
type: string | |||
wait_draw_im_user_ids: | |||
type: string | |||
wait_draw_user_ids: | |||
type: string | |||
type: object | |||
pb.SendRedPacketResp: | |||
properties: | |||
seq: | |||