feat : coupon
This commit is contained in:
@@ -385,7 +385,7 @@ trait OrderTrait
|
|||||||
if (in_array($couponInfo->status,[CouponCode::COUPON_STATUS_USED,CouponCode::COUPON_STATUS_EXPIRE])) throw new ErrException('优惠券已经被使用');
|
if (in_array($couponInfo->status,[CouponCode::COUPON_STATUS_USED,CouponCode::COUPON_STATUS_EXPIRE])) throw new ErrException('优惠券已经被使用');
|
||||||
|
|
||||||
$couponTemplateInfo = $this->couponTemplateModel->getInfoById($couponInfo->coupon_template_id);
|
$couponTemplateInfo = $this->couponTemplateModel->getInfoById($couponInfo->coupon_template_id);
|
||||||
if (empty($couponTempleteInfo)) throw new ErrException('优惠券信息错误');
|
if (empty($couponTemplateInfo)) throw new ErrException('优惠券信息错误');
|
||||||
|
|
||||||
$this->couponId = $couponInfo->id;
|
$this->couponId = $couponInfo->id;
|
||||||
$this->orderRes['coupon_info'] = [
|
$this->orderRes['coupon_info'] = [
|
||||||
|
|||||||
Reference in New Issue
Block a user