shish 2 anni fa
parent
commit
b42cff80f7
1 ha cambiato i file con 8 aggiunte e 0 eliminazioni
  1. 8 0
      app-ghs/controllers/ShopController.php

+ 8 - 0
app-ghs/controllers/ShopController.php

@@ -31,8 +31,16 @@ class ShopController extends BaseController
     public function actionChangeWx()
     public function actionChangeWx()
     {
     {
         $get = Yii::$app->request->get();
         $get = Yii::$app->request->get();
+        $isApple = $get['isApple'] ?? 0;
         $url = $get['url'] ?? '';
         $url = $get['url'] ?? '';
         $shop = $this->shop;
         $shop = $this->shop;
+        if (isset($shop->hasRenew) && $shop->hasRenew == 0) {
+            if ($isApple == 1) {
+                util::fail('请用小程序操作');
+            } else {
+                util::fail('请先续期一年');
+            }
+        }
         $shop->superWx = $url;
         $shop->superWx = $url;
         $shop->save();
         $shop->save();
         util::complete('修改成功');
         util::complete('修改成功');