From efba0c4c596ea3825690c82e05ab354c0e02ecf3 Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Thu, 25 Jul 2024 17:48:18 +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/public_platoon_settle.go | 3 ++- app/svc/svc_comm_deal_commission.go | 2 +- app/svc/svc_deal_commission.go | 6 ++++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/app/svc/public_platoon_settle.go b/app/svc/public_platoon_settle.go index 4574181..8f61647 100644 --- a/app/svc/public_platoon_settle.go +++ b/app/svc/public_platoon_settle.go @@ -76,7 +76,7 @@ func PublicPlatoonAddRecord(eg *xorm.Engine, ItemTitle, ordId string, uid, coinI } return true } -func PublicPlatoonAddRecordWithSession(session *xorm.Session, ItemTitle, ordId string, uid, coinId, kind, types int, amount float64, beforeAmount string) bool { +func PublicPlatoonAddRecordWithSession(session *xorm.Session, ItemTitle, ordId string, uid, coinId, kind, types int, amount float64, beforeAmount, source string) bool { now := time.Now() finUserFlow := model.UserPublicPlatoonIncomeRecords{ @@ -91,6 +91,7 @@ func PublicPlatoonAddRecordWithSession(session *xorm.Session, ItemTitle, ordId s Title: ItemTitle, BeforeAmount: beforeAmount, Oid: ordId, + Source: source, } _, err := session.Insert(&finUserFlow) if err != nil { diff --git a/app/svc/svc_comm_deal_commission.go b/app/svc/svc_comm_deal_commission.go index 7231d04..5f6d1b4 100644 --- a/app/svc/svc_comm_deal_commission.go +++ b/app/svc/svc_comm_deal_commission.go @@ -293,7 +293,7 @@ func CommCommSettleMoney(session *xorm.Session, item *model.CommOrdListRelate, a kind = 5 title = "直推奖" } - bools := PublicPlatoonAddRecordWithSession(session, title, utils.Int64ToStr(item.Oid), item.Uid, 0, kind, 0, item.Amount, beforeAmount) + bools := PublicPlatoonAddRecordWithSession(session, title, utils.Int64ToStr(item.Oid), item.Uid, 0, kind, 0, item.Amount, beforeAmount, mapData["title"]+"奖励") if bools == false { return false } diff --git a/app/svc/svc_deal_commission.go b/app/svc/svc_deal_commission.go index aa258f7..8696a20 100644 --- a/app/svc/svc_deal_commission.go +++ b/app/svc/svc_deal_commission.go @@ -312,6 +312,7 @@ func CommSettleMoney(session *xorm.Session, item *model.TaskOrdListRelate, appNa if item.Pvd == "adset_video" { ItemTitle = "看视频奖励" } + titles := ItemTitle if item.Level > 0 { ItemTitle = "团队任务奖励" if item.Pvd == "adset_video" { @@ -354,7 +355,7 @@ func CommSettleMoney(session *xorm.Session, item *model.TaskOrdListRelate, appNa kind = 5 title = "直推奖" } - bools := PublicPlatoonAddRecordWithSession(session, title, utils.Int64ToStr(item.Oid), item.Uid, 0, kind, 0, item.Amount, beforeAmount) + bools := PublicPlatoonAddRecordWithSession(session, title, utils.Int64ToStr(item.Oid), item.Uid, 0, kind, 0, item.Amount, beforeAmount, titles) if bools == false { return false } @@ -410,6 +411,7 @@ func CommSettleVirtualCoin(session *xorm.Session, virtualCoinRelateItem *model.V if mapData["title"] != "" { title = mapData["title"] + "奖励" } + titles := title if virtualCoinRelateItem.Level > 0 { title = "团队任务奖励" if virtualCoinRelateItem.Pvd == "adset_video" { @@ -445,7 +447,7 @@ func CommSettleVirtualCoin(session *xorm.Session, virtualCoinRelateItem *model.V kind = 5 title = "直推奖" } - bools := PublicPlatoonAddRecordWithSession(session, title, utils.Int64ToStr(virtualCoinRelateItem.Oid), virtualCoinRelateItem.Uid, virtualCoinRelateItem.CoinId, kind, 0, utils.StrToFloat64(virtualCoinRelateItem.Amount), beforeAmount) + bools := PublicPlatoonAddRecordWithSession(session, title, utils.Int64ToStr(virtualCoinRelateItem.Oid), virtualCoinRelateItem.Uid, virtualCoinRelateItem.CoinId, kind, 0, utils.StrToFloat64(virtualCoinRelateItem.Amount), beforeAmount, titles) if bools == false { return false }