Explorar o código

修改货位号

shish %!s(int64=2) %!d(string=hai) anos
pai
achega
907cb31197
Modificáronse 1 ficheiros con 17 adicións e 0 borrados
  1. 17 0
      app-ghs/controllers/PurchaseOrderController.php

+ 17 - 0
app-ghs/controllers/PurchaseOrderController.php

@@ -18,6 +18,23 @@ use Yii;
 class PurchaseOrderController extends BaseController
 {
 
+    //修改货位号 ssh 20240410
+    public function actionModifySeatSn()
+    {
+        $get = Yii::$app->request->get();
+        $id = $get['id'] ?? 0;
+        $seatSn = $get['seatSn'] ?? '';
+        $cg = PurchaseOrderClass::getById($id, true);
+        if (empty($cg)) {
+            util::fail('没有找到采购单');
+        }
+        if ($cg->mainId != $this->mainId) {
+            util::fail('没有权限');
+        }
+        $cg->seatSn = $seatSn;
+        $cg->save();
+    }
+
     //获取零售端在进行中的订单 ssh 20231201
     public function actionGetLsRunningOrderNum()
     {