瀏覽代碼

蜂鸟授权地址不管线上还是测试,统一修改为测试回调地址进行测试,后期修改回来

shizhongqi 8 月之前
父節點
當前提交
328107d527
共有 2 個文件被更改,包括 6 次插入3 次删除
  1. 6 2
      app-ghs/controllers/DeliveryController.php
  2. 0 1
      app-hd/controllers/GhsController.php

+ 6 - 2
app-ghs/controllers/DeliveryController.php

@@ -126,7 +126,10 @@ class DeliveryController extends BaseController
     {
         $fengnaioAuth = new \common\components\delivery\platform\fengniao\Auth();
         $mainId = $this->mainId;
-        $redirectUrl = Yii::$app->params['ghsHost'] . '/delivery/fengniao-auth-callback' . '?main_id=' . $mainId;
+        // $apiHost = Yii::$app->params['ghsHost'];
+        // TODO 暂时修改为测试环境
+        $apiHost = 'https://api.shop.hzghd.com';
+        $redirectUrl = $apiHost . '/delivery/fengniao-auth-callback' . '?main_id=' . $mainId;
         $authUrl = $fengnaioAuth->generateAuthUrl($redirectUrl);
 
         util::success(['url'=>$authUrl]);
@@ -261,7 +264,7 @@ class DeliveryController extends BaseController
         $remark = $post['remark'] ?? '';
 
         $adminId = $this->adminId;
-        util::checkRepeatCommit($adminId, 4);
+        util::checkRepeatCommit($adminId, 3);
 
         $orderId = intval($post['orderId']);
         $order = OrderClass::getById($orderId);
@@ -773,6 +776,7 @@ class DeliveryController extends BaseController
         if(!isset($get['main_id'])){
             Yii::error('蜂鸟授权回调的回调地址 authCallbackUrl 中没有带 main_id');
             noticeUtil::push('蜂鸟授权回调的回调地址 authCallbackUrl 中没有带 main_id,回调数据:' . json_encode($callbackData, JSON_UNESCAPED_UNICODE), 'fengniao');
+            return;
         }
 
         $mainId = $get['main_id'];

+ 0 - 1
app-hd/controllers/GhsController.php

@@ -10,7 +10,6 @@ use bizGhs\custom\classes\CustomLevelClass;
 use bizGhs\merchant\classes\WlClass;
 use bizHd\purchase\classes\PurchaseClass;
 use bizHd\shop\classes\ShopExtClass;
-use bizHd\shop\models\ShopExt;
 use bizGhs\stat\classes\StatVisitClass;
 use common\components\dict;
 use common\components\imgUtil;