Jelajahi Sumber

没有openId

shish 3 tahun lalu
induk
melakukan
51dee28d19
1 mengubah file dengan 3 tambahan dan 2 penghapusan
  1. 3 2
      app-hd/controllers/LjhController.php

+ 3 - 2
app-hd/controllers/LjhController.php

@@ -22,7 +22,7 @@ use common\components\util;
 class LjhController extends BaseController
 {
 
-    public $guestAccess = ['apply','detail','wx-pay'];
+    public $guestAccess = ['apply', 'detail', 'wx-pay'];
 
     public function actionDetail()
     {
@@ -120,8 +120,9 @@ class LjhController extends BaseController
             $admin = $this->admin;
             $openId = $admin->miniOpenId ?? '';
         }
+        //没有openId
         if (empty($openId)) {
-            util::fail('出错了,请联系客服');
+            util::success(['hasNoMiniOpenId' => 1]);
         }
         $purchaseCapital = dict::getDict('capitalType', 'ljhApply', 'id');
         //流水类型、优惠卷、微信支付(h5还是小程序支付)类型 带到回调