From f056ad96e6b27deb312cec849357394acfc9574e Mon Sep 17 00:00:00 2001 From: huangjiajun <582604932@qq.com> Date: Tue, 29 Nov 2022 17:33:31 +0800 Subject: [PATCH] =?UTF-8?q?add=20reverse:for=20v4.1.7=20=E7=A7=AF=E5=88=86?= =?UTF-8?q?=E9=87=8A=E6=94=BE=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rule/integral_release_settlement.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rule/integral_release_settlement.go b/rule/integral_release_settlement.go index d0854d3..c0cee63 100644 --- a/rule/integral_release_settlement.go +++ b/rule/integral_release_settlement.go @@ -468,6 +468,10 @@ func DealIntegralReleaseInterpositionUserAmount(session *xorm.Session, req md.De integralReleaseInterpositionUserFlow.BeforeAlreadyAmount = alreadyAmountValue.String() integralReleaseInterpositionUserFlow.AfterAlreadyAmount = alreadyAmountValue.String() } else if req.Kind == "sub" { + if zhios_order_relate_utils.StrToFloat64(waiteAmountValue.Sub(amountValue).String()) < 0 { //不够扣就把剩余的扣了 + amountValue = waiteAmountValue + req.Amount = zhios_order_relate_utils.StrToFloat64(waiteAmountValue.String()) + } integralReleaseInterpositionUserFlow.Kind = 2 integralReleaseInterpositionUserFlow.BeforeTotalAmount = totalAmountValue.String() integralReleaseInterpositionUserFlow.AfterTotalAmount = totalAmountValue.String()