From d79bc9d106dd074f0e9e5a8df43a5e3efda72d2b Mon Sep 17 00:00:00 2001 From: Lemon <15040771@qq.com> Date: Mon, 19 Oct 2020 14:04:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E6=83=A0=E5=88=B8=E9=9D=9E=E6=96=B0?= =?UTF-8?q?=E7=94=A8=E6=88=B7=E6=8A=A5=E9=94=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Controller/v3/CouponController.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/Controller/v3/CouponController.php b/app/Controller/v3/CouponController.php index a17b7ba..d82268a 100644 --- a/app/Controller/v3/CouponController.php +++ b/app/Controller/v3/CouponController.php @@ -90,7 +90,13 @@ class CouponController extends BaseController ->whereIn('state',OrderState::REFUND) ->exists(); if($newUserCheck){ - throw new ErrorCodeException(ErrorCode::COUPON_IS_NOT_NEW_USER,'',$userId); + return $this->result( + ErrorCode::COUPON_IS_NOT_NEW_USER, + [ + 'text'=>'关注懒族菜市微信公众号,更多精彩活动一手掌握!' + ], + '不是新用户无法领券' + ); } $res = $this->couponRecService->getAvailableList($userId,$receiveType); return $this->success($res);