shish 3 月之前
父節點
當前提交
f15d925694
共有 1 個文件被更改,包括 10 次插入6 次删除
  1. 10 6
      biz-ghs/order/classes/OrderClass.php

+ 10 - 6
biz-ghs/order/classes/OrderClass.php

@@ -2,6 +2,7 @@
 
 namespace bizGhs\order\classes;
 
+use bizGhs\custom\classes\DistClass;
 use bizGhs\item\classes\ItemClassClass;
 use bizHd\purchase\classes\PurchaseItemClass;
 use common\components\arrayUtil;
@@ -450,7 +451,7 @@ class OrderClass extends BaseClass
         $customId = $order->customId ?? 0;
         $custom = CustomClass::getById($customId, true);
         if (empty($custom)) {
-            util::fail('没有找到客户信息,编号:'.$customId);
+            util::fail('没有找到客户信息,编号:' . $customId);
         }
         $shopId = $custom->shopId ?? 0;
         $customShop = ShopClass::getById($shopId, true);
@@ -1515,7 +1516,7 @@ class OrderClass extends BaseClass
             } else {
                 $content .= $productNum . ' = ' . $productPrice . '元  ' . ($ratioType == 0 ? $ratio . '支装' : ($ratioType == 1 ? '若干支装' : '')) . '<BR>';
             }
-        }else{
+        } else {
             $content .= ' ' . ($ratioType == 0 ? $ratio . '支装' : ($ratioType == 1 ? '若干支装' : '')) . '<BR>';
         }
         $content .= '--------------------------------<BR>';
@@ -1900,7 +1901,7 @@ class OrderClass extends BaseClass
         /**************************如果是好多花的云仓还要再打一下标签纸,多处要同步修改,关键词 hdh_yc *****************************/
         $orderMainId = $orderInfo['mainId'] ?? 0;
         if (getenv('YII_ENV') == 'production') {
-            $map = [65726, 58, 25119,28500];
+            $map = [65726, 58, 25119, 28500];
         } else {
             $map = [828];
         }
@@ -2958,7 +2959,7 @@ XL;
         /**************************如果是好多花的云仓还要再打一下标签纸,多处要同步修改,关键词 hdh_yc *****************************/
         $orderMainId = $order->mainId;
         if (getenv('YII_ENV') == 'production') {
-            $map = [65726, 58, 25119,28500];
+            $map = [65726, 58, 25119, 28500];
         } else {
             $map = [828];
         }
@@ -2992,6 +2993,9 @@ XL;
         if (empty($wlName)) {
             $wlName = $shortRemark;
         }
+        $distId = $custom->distId ?? '';
+        $dist = DistClass::getById($distId, true);
+        $distName = $dist->name ?? '';
 
         $address = $order->address ?? '';
         $floor = $order->floor ?? '';
@@ -3056,9 +3060,9 @@ XL;
             $content .= '<TEXT x="290" y="30" font="12" w="2" h="3" r="90">' . $customName . '</TEXT>';
             $content .= '<TEXT x="195" y="30" font="12" w="1" h="2" r="90">' . $fullAddress . '</TEXT>';
             $content .= '<TEXT x="128" y="30" font="12" w="2" h="2" r="90">' . $customMobile . ' ' . $itemNum . '扎</TEXT>';
-            //福州易批花,不仅要自动打印,还要打印出物流名称
+            //福州易批花,温州易批花,不仅要自动打印,还要打印出物流名称
             if ($orderMainId == 25119 || $orderMainId == 28500) {
-                $content .= '<TEXT x="70" y="30" font="12" w="2" h="2" r="90">物流 ' . $wlName .' '.$payDate. '</TEXT>';
+                $content .= '<TEXT x="70" y="30" font="12" w="2" h="2" r="90">片区 ' . $distName . ' ' . $payDate . '</TEXT>';
             }
             /**************************如果是好多花的云仓还要再打一下标签纸,多处要同步修改,关键词 hdh_yc *****************************/
         }