From ab4444a6f300f1674b029ac18504171d09353687 Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Wed, 24 Apr 2024 20:06:25 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/svc/svc_deal_commission.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/svc/svc_deal_commission.go b/app/svc/svc_deal_commission.go index 77f3905..78cfb63 100644 --- a/app/svc/svc_deal_commission.go +++ b/app/svc/svc_deal_commission.go @@ -127,8 +127,8 @@ func ConvertList2Map(a []*comm_plan.VirtualCoinCommission) (b map[string]float64 func CommCombineVirtualCoinRelateData(lvUser *comm_plan.LvUser, oid int64, pvd string, level int, mapData map[string]string) []*model.VirtualCoinRelate { mode := mapData["mode"] - var data []*model.VirtualCoinRelate - if mapData["reward_type"] != "2" { + var data = make([]*model.VirtualCoinRelate, 0) + if mapData["reward_type"] != "2" && level == 0 { //可能没有极差返利 只有补贴 profitList := lvUser.ProfitList if len(profitList) == 0 { @@ -186,7 +186,6 @@ func CommCombineVirtualCoinRelateData(lvUser *comm_plan.LvUser, oid int64, pvd s } } } - if lvUser.ParentUser != nil { level += 1 data = append(data, CommCombineVirtualCoinRelateData(lvUser.ParentUser, oid, pvd, level, mapData)...)