From 12afac9595589b78b8cc384b5d08a04cb644b1bb Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Fri, 19 Jul 2024 10:34:40 +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 --- rule/consume_integral_settlement.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/rule/consume_integral_settlement.go b/rule/consume_integral_settlement.go index a49dd2b..ef9b2e2 100644 --- a/rule/consume_integral_settlement.go +++ b/rule/consume_integral_settlement.go @@ -139,14 +139,14 @@ func DailySettlementBlockConsumeIntegral(engine *xorm.Engine, mid string, isTask if hasConsumeTotal > 0 { for _, v := range subsidyWithUserForConsumeList { - if v.LeaveDay > 0 && userStatusList[v.Uid]["status"] != "1" { + if v.LeaveDay > 0 && userStatusList[v.Uid]["status"] == "1" { consumeTotalMap[v.Uid] = consumeTotalMap[v.Uid].Add(decimal.NewFromFloat(consumeValue)) consumeTotalCountMap[v.Uid]++ totalMap[v.Uid] = totalMap[v.Uid].Add(decimal.NewFromFloat(consumeValue)) consumeValueTotal = consumeValueTotal.Add(decimal.NewFromFloat(consumeValue)) } var err1 error - if userStatusList[v.Uid]["status"] != "1" { + if userStatusList[v.Uid]["status"] == "1" { err1 = DealUserConsumeIntegral(session, &v, consumeValue, mid) } else { err1 = DealUserConsumeIntegralStop(session, &v, consumeValue, mid, storeStatusList[v.Uid]["date"]) @@ -178,14 +178,14 @@ func DailySettlementBlockConsumeIntegral(engine *xorm.Engine, mid string, isTask return err, totalMap, storeTotalMap } for _, v := range subsidyWithUserForExperienceList { - if v.LeaveDay > 0 && userStatusList[v.Uid]["status"] != "1" { + if v.LeaveDay > 0 && userStatusList[v.Uid]["status"] == "1" { experienceTotalCountMap[v.Uid]++ totalMap[v.Uid] = totalMap[v.Uid].Add(decimal.NewFromFloat(experienceValue)) experienceTotalMap[v.Uid] = experienceTotalMap[v.Uid].Add(decimal.NewFromFloat(experienceValue)) experienceValueTotal = experienceValueTotal.Add(decimal.NewFromFloat(experienceValue)) } var err1 error - if userStatusList[v.Uid]["status"] != "1" { + if userStatusList[v.Uid]["status"] == "1" { err1 = DealUserExperienceIntegral(session, &v, experienceValue, mid) } else { err1 = DealUserExperienceIntegralStop(session, &v, experienceValue, mid, userStatusList[v.Uid]["date"]) @@ -215,7 +215,7 @@ func DailySettlementBlockConsumeIntegral(engine *xorm.Engine, mid string, isTask num := zhios_order_relate_utils.StrToFloat64(v.IntegralNum) / zhios_order_relate_utils.StrToFloat64(subsidyBase.ConsumptionIntegral) storeValue := zhios_order_relate_utils.FloatFormat(consumeValue*num, 2) var err1 error - if storeStatusList[v.Uid]["status"] != "1" { + if storeStatusList[v.Uid]["status"] == "1" { storeTotalCountMap[v.Uid] += int(num) storeTotalMap[v.Uid] = storeTotalMap[v.Uid].Add(decimal.NewFromFloat(storeValue)) storeValueTotal = storeValueTotal.Add(decimal.NewFromFloat(storeValue))