diff --git a/api/v1/cmb_cpn.proto b/api/v1/cmb_cpn.proto index 59cf40a..fd8a20b 100644 --- a/api/v1/cmb_cpn.proto +++ b/api/v1/cmb_cpn.proto @@ -120,6 +120,11 @@ message CmbQueryProductReply { string availableStock = 17 [json_name = "availableStock"]; // 细则描述 string detail = 18 [json_name = "detail"]; + + // 批次开始日期 格式yyyy-mm-dd hh:mm:ss.sss + string saleStartTime = 19 [json_name = "saleStartTime"]; + // 批次结束时间,格式yyyy-mm-dd hh:mm:ss.sss + string saleEndTime = 20 [json_name = "saleEndTime"]; } diff --git a/internal/biz/cmb.go b/internal/biz/cmb.go index 8f57509..4d8e125 100644 --- a/internal/biz/cmb.go +++ b/internal/biz/cmb.go @@ -121,6 +121,9 @@ func (v *VoucherBiz) CmbProductQuery(ctx context.Context, productNo string) (rep EndTime: *wechatResp.AvailableEndTime, AvailableStock: "", Detail: *wechatResp.Description, + + SaleStartTime: *wechatResp.StartTime, + SaleEndTime: *wechatResp.StopTime, } reps.Amount = fmt.Sprintf("%d", *wechatResp.StockUseRule.FixedNormalCoupon.CouponAmount)