From 492f447c7a6937bb1fda9ae792912d4b99c106bb Mon Sep 17 00:00:00 2001 From: shenjiachi Date: Mon, 23 Dec 2024 09:59:33 +0800 Subject: [PATCH] update withdraw apply list alipay account --- app/md/financial_center/md_withdraw.go | 8 ++++---- app/svc/financial_center/svc_withdraw.go | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/app/md/financial_center/md_withdraw.go b/app/md/financial_center/md_withdraw.go index 96d2d02..2c056a2 100644 --- a/app/md/financial_center/md_withdraw.go +++ b/app/md/financial_center/md_withdraw.go @@ -82,10 +82,10 @@ type WithdrawApplyInfo struct { model.FinWithdrawApply `xorm:"extends"` Nickname string `xorm:"nickname"` // 用户名称 ParentID int64 `xorm:"parent_uid"` // 推荐人ID - AliPayName string `xorm:"user_name"` // 支付宝昵称 - AliPayAccount string `xorm:"user_id"` // 支付宝账号 - WxPayName string `xorm:"user_name"` // 微信昵称 - WxPayAccount string `xorm:"user_id"` // 微信账号 + AliPayName string `xorm:"alipay_user_name"` // 支付宝昵称 + AliPayAccount string `xorm:"alipay_open_id"` // 支付宝账号 + WxPayName string `xorm:"wx_user_name"` // 微信昵称 + WxPayAccount string `xorm:"wx_user_id"` // 微信账号 InviteCode string `xorm:"system_invite_code"` // 邀请码 } diff --git a/app/svc/financial_center/svc_withdraw.go b/app/svc/financial_center/svc_withdraw.go index b0ef5af..1e7f6b8 100644 --- a/app/svc/financial_center/svc_withdraw.go +++ b/app/svc/financial_center/svc_withdraw.go @@ -82,7 +82,8 @@ func WithDrawManagementGetApply(engine *xorm.Engine, req *md.GetWithdrawApplyLis if req.Level != "" { session = session.Where("usera.level = ?", req.Level) } - total, err := session.Limit(req.Limit, (req.Page-1)*req.Limit).Asc("apply.id").FindAndCount(&applies) + total, err := session.Select("apply.*, alipay.open_id as alipay_open_id, alipay.user_name as alipay_user_name, wx.user_id as wx_user_id, wx.user_name as wx_user_name, usera.system_invite_code as system_invite_code"). + Limit(req.Limit, (req.Page-1)*req.Limit).Asc("apply.id").FindAndCount(&applies) if err != nil { return nil, 0, err }