多笔立减金

This commit is contained in:
ziming 2025-12-18 15:05:57 +08:00
parent c3d5f18e68
commit c490f8335d
2 changed files with 6 additions and 32 deletions

View File

@ -240,10 +240,11 @@ func (biz *MultiBiz) nlCreate(ctx context.Context, req *bo.WechatVoucherNotifyBo
ConsumeAmount: mnd.ConsumeAmount,
ConsumeTime: mnd.ConsumeTime,
TransactionID: req.PlainText.ConsumeInformation.TransactionID,
RequestURL: order.NotifyUrl,
RequestStatus: vo.MultiNotifyLogStatusWait.GetValue(),
OrderCreateTime: order.CreateTime,
CouponCreateTime: &req.PlainText.CreateTime,
//RequestURL: order.NotifyUrl,
RequestURL: biz.bc.Cmb.MultiNotifyUrl,
RequestStatus: vo.MultiNotifyLogStatusWait.GetValue(),
OrderCreateTime: order.CreateTime,
CouponCreateTime: &req.PlainText.CreateTime,
}
request, err := biz.GetRequest(ctx, nl, order)

View File

@ -57,34 +57,7 @@ func Test_MarketingQuery(t *testing.T) {
func Test_QixingNotifyData(t *testing.T) {
wxBody := `{
"id": "4ab2699d-e91d-5460-9810-25fd6d4c69a5",
"create_time": "2025-12-08T17:54:24+08:00",
"resource_type": "encrypt-resource",
"event_type": "COUPON.USE",
"summary": "代金券核销通知",
"original_type": "coupon",
"associated_data": "coupon",
"plain_text": {
"stock_creator_mchid": "1652465541",
"stock_id": "21386484",
"coupon_id": "142388354994",
"coupon_name": "银行卡多笔立减",
"description": "",
"status": "SENDED",
"create_time": "2025-12-08T17:50:48+08:00",
"coupon_type": "NORMAL",
"no_cash": false,
"singleitem": false,
"business_type": "",
"consume_information": {
"consume_time": "2025-12-08T17:54:24+08:00",
"consume_mchid": "1274938601",
"transaction_id": "4200002996202512083063051834",
"consume_amount": 16
}
}
}`
wxBody := `{"id":"4ab2699d-e91d-5460-9810-25fd6d4c69a5","create_time":"2025-12-08T17:54:24+08:00","resource_type":"encrypt-resource","event_type":"COUPON.USE","summary":"代金券核销通知","original_type":"coupon","associated_data":"coupon","plain_text":{"stock_creator_mchid":"1652465541","stock_id":"21386484","coupon_id":"142388354994","coupon_name":"银行卡多笔立减","description":"","status":"SENDED","create_time":"2025-12-08T17:50:48+08:00","coupon_type":"NORMAL","no_cash":false,"singleitem":false,"business_type":"","consume_information":{"consume_time":"2025-12-08T17:54:24+08:00","consume_mchid":"1274938601","transaction_id":"4200002996202512083063051834","consume_amount":16}}}`
content := base64.StdEncoding.EncodeToString([]byte(wxBody))
ciphertext := helper.Md5(content + "DrY1zLkOH01q0sN66vrmkdpbWsyb41ho")