Browse Source

查看采购单

shish 2 months ago
parent
commit
75bd757fdf
1 changed files with 7 additions and 6 deletions
  1. 7 6
      app-hd/controllers/PurchaseController.php

+ 7 - 6
app-hd/controllers/PurchaseController.php

@@ -1057,18 +1057,19 @@ class PurchaseController extends BaseController
             util::fail('请选择合并采购单');
         }
         $salt = $get['salt'] ?? '';
-        if (empty($this->shopId)) {
-            if (empty($salt)) {
-                util::fail('请求参数错误');
-            }
+        if (!empty($salt)) {
             if (empty($mergeSn->salt) || $mergeSn->salt != $salt) {
-                util::fail('找不到订单');
+                util::fail('此单无法查看哦');
             }
         } else {
+            if (empty($this->shopId)) {
+                util::fail('暂时不能查看');
+            }
             if ($mergeSn->mainId != $this->mainId) {
-                util::fail('不是你的订单');
+                util::fail('此单无法查看哈');
             }
         }
+
         $ghsId = $mergeSn->ghsId ?? 0;
         $where = [
             'ghsId' => $ghsId,