From 16aab5156c5015d78362b650136dcd04b86a5692 Mon Sep 17 00:00:00 2001 From: suyl <770236076@qq.com> Date: Thu, 27 May 2021 14:47:08 +0800 Subject: [PATCH] aa --- business/jxutils/weixinmsg/weixinmsg.go | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/business/jxutils/weixinmsg/weixinmsg.go b/business/jxutils/weixinmsg/weixinmsg.go index 122f18f13..e74674820 100644 --- a/business/jxutils/weixinmsg/weixinmsg.go +++ b/business/jxutils/weixinmsg/weixinmsg.go @@ -427,13 +427,23 @@ func NotifyOrderCanceled(order *model.GoodsOrder) (err error) { suffix = storeDetail.CityName + "," + storeDetail.Name } title := fmt.Sprintf(suffix+"老板,您的订单%s第%d号订单, %s被取消了!", model.VendorChineseNames[order.VendorID], order.OrderSeq, order.VendorOrderID) + var price int64 + if beego.BConfig.RunMode == "jxgy" { + price = order.NewEarningPrice + } else { + if order.EarningType == model.EarningTypePoints { + price = order.ActualPayPrice + } else { + price = order.EarningPrice + } + } data := map[string]interface{}{ "first": map[string]interface{}{ "value": title, "color": WX_NEW_ORDER_TEMPLATE_COLOR, }, "orderProductPrice": map[string]interface{}{ - "value": jxutils.IntPrice2StandardCurrencyString(order.ActualPayPrice), + "value": jxutils.IntPrice2StandardCurrencyString(price), "color": WX_NEW_ORDER_TEMPLATE_COLOR, }, "orderProductName": map[string]interface{}{