shish 8 месяцев назад
Родитель
Сommit
118286fcb5
1 измененных файлов с 5 добавлено и 2 удалено
  1. 5 2
      app-hd/controllers/GhsController.php

+ 5 - 2
app-hd/controllers/GhsController.php

@@ -320,8 +320,11 @@ class GhsController extends BaseController
         if (!empty($this->shopId)) {
 
             $current = ShopClass::getById($shopId, true);
-            if (!isset($current->ptStyle) || $current->ptStyle != dict::getDict('ptStyle', 'ghs')) {
-                util::fail('没有找到批发店');
+            if (empty($current)) {
+                util::fail('没有找到批发店,rid-186');
+            }
+            if ($current->ptStyle != dict::getDict('ptStyle', 'ghs')) {
+                util::fail('没有找到批发店,rid-195');
             }
 
             $ghs = GhsClass::build($shopId, $this->shopId);