From c3a719e955015f8ac4007d1e6f44dd1baaf3077b Mon Sep 17 00:00:00 2001
From: huangxiaoqiang <huangxiaoqiang@hnkhzn.com>
Date: 星期五, 10 一月 2025 18:40:16 +0800
Subject: [PATCH] 新增补录数据按钮

---
 Code Management/WMS/WIDESEA_WMSClient/src/api/buttons.js                                             |    9 +++
 Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx          |   19 +++++
 Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/extend/SupplementationData.vue |  104 ++++++++++++++++++++++++++++++++++
 3 files changed, 130 insertions(+), 2 deletions(-)

diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/api/buttons.js b/Code Management/WMS/WIDESEA_WMSClient/src/api/buttons.js
index 7e2d3a4..812e7d4 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/api/buttons.js
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/api/buttons.js
@@ -131,6 +131,15 @@
     onClick: function () {
       
     }
+    
+  },{
+    name: '琛ュ綍鏁版嵁',
+    type: 'primary',
+    // color: '#529b2e',
+    value: 'SupplementationData',
+    onClick: function () {
+      
+    }
   }
 ]
 
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx b/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx
index ec08e49..925a93e 100644
--- a/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx
@@ -8,12 +8,12 @@
 //姝s鏂囦欢鏄敤鏉ヨ嚜瀹氫箟鎵╁睍涓氬姟浠g爜锛屽彲浠ユ墿灞曚竴浜涜嚜瀹氫箟椤甸潰鎴栬�呴噸鏂伴厤缃敓鎴愮殑浠g爜
 
 // import gridHeader from "./demo_Product/Dt_BillGroupStockDetail.vue";
-
+import gridBody from "./extend/SupplementationData.vue"
 let extension = {
   components: {
     //鏌ヨ鐣岄潰鎵╁睍缁勪欢
     gridHeader: '',
-    gridBody: '',
+    gridBody: gridBody,
     gridFooter: '',
     //鏂板缓銆佺紪杈戝脊鍑烘鎵╁睍缁勪欢
     modelHeader: '',
@@ -55,6 +55,21 @@
             })
         }
       }
+
+      var btnSupplementationData = this.buttons.find(x => x.value == "SupplementationData");
+            if (btnSupplementationData != null) {
+                btnSupplementationData.onClick = () => {
+                    let rows = this.$refs.table.getSelected();
+                        if (rows.length == 0) {
+                            return this.$error("璇烽�夋嫨鏁版嵁!");
+                        } else if (rows.length > 1) {
+                            return this.$error("鍙兘閫夋嫨鍗曟潯鏁版嵁");
+                        }
+                        this.$refs.gridBody.open(rows[0].palletCode);
+                        this.refresh();
+                    }
+                
+                }
       //绀轰緥锛氬湪鎸夐挳鐨勬渶鍓嶉潰娣诲姞涓�涓寜閽�
       // this.buttons.unshift({
       //   //涔熷彲浠ョ敤push鎴栬�卻plice鏂规硶鏉ヤ慨鏀筨uttons鏁扮粍
diff --git a/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/extend/SupplementationData.vue b/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/extend/SupplementationData.vue
new file mode 100644
index 0000000..36021ba
--- /dev/null
+++ b/Code Management/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/extend/SupplementationData.vue
@@ -0,0 +1,104 @@
+<template>
+  <vol-box v-model="show" title="琛ュ綍鏁版嵁" :width="800" :height="600">
+    <template #content>
+      <el-form ref="form" :model="form" label-width="90px">
+        <el-form-item label="鎵樼洏鍙�">
+          <el-input type="text" v-model="this.form.palletCode" readonly></el-input>
+        </el-form-item>
+        <el-form-item label="鍑哄簱OR鍏ュ簱" prop="OutIn">
+          <el-select v-model="OutIn" placeholder="璇烽�夋嫨鍑哄簱Or鍏ュ簱">
+            <el-option label="鍑哄簱" value="Out" />
+            <el-option label="鍏ュ簱" value="In" />
+          </el-select>
+        </el-form-item>
+        <el-form-item label="鍖哄煙" prop="areaID">
+          <el-select v-model="form.areaID" placeholder="璇烽�夋嫨鍖哄煙">
+            <el-option label="闄堝寲" value="1" />
+            <el-option label="闈欑疆" value="2" />
+            <el-option label="鍒嗗" value="3" />
+            <el-option label="楂樻俯" value="4" />
+            <el-option label="甯告俯1" value="5" />
+            <el-option label="甯告俯2" value="6" />
+            <el-option label="甯告俯3" value="7" />
+          </el-select>
+        </el-form-item>
+      </el-form>
+    </template>
+    <template #footer>
+      <div>
+        <el-button type="danger" size="small" plain @click="submit">
+          <i class="el-icon-check">纭</i>
+        </el-button>
+        <el-button size="small" type="primary" plain @click="() => {
+            this.show = false;
+          }
+          ">
+          <i class="el-icon-close">鍏抽棴</i>
+        </el-button>
+      </div>
+    </template>
+  </vol-box>
+</template>
+
+<script>
+import VolBox from "@/components/basic/VolBox.vue";
+export default {
+  components: {
+    "vol-box": VolBox,
+  },
+  data() {
+    return {
+      OutIn:"",
+      form:{
+        areaID:"",
+        palletCode:""
+      },
+      show: false,
+    };
+  },
+  methods: {
+    open(palletCode) {
+      this.show = true;
+      this.form.palletCode=palletCode;
+    },
+    submit() {
+      this.$emit("parentCall", ($vue) => {
+        if (
+          !this.OutIn ||
+          !this.form.areaID ||
+          !this.form.palletCode||
+          this.OutIn==""||
+          this.form.areaID==""||
+          this.form.palletCode==""
+        ) {
+          this.$message.error("鍙傛暟閿欒");
+          return;
+        }
+        if(this.OutIn=="Out"){
+          this.http.post("api/ProcessApply/StockOutDataBack", this.form, "").then((x) => {
+          if (!x.status) {
+            this.$message.error(x.message);
+          } else {
+            this.$Message.success("鎴愬姛");
+            this.show = false;
+            $vue.refresh();
+          }
+        });
+        }else if(this.OutIn=="In"){
+          this.http.post("api/ProcessApply/StockInDataBack", this.form, "").then((x) => {
+          if (!x.status) {
+            this.$message.error(x.message);
+          } else {
+            this.$Message.success("鎴愬姛");
+            this.show = false;
+            $vue.refresh();
+          }
+        });
+        }
+        
+      });
+    },
+  },
+
+};
+</script>
\ No newline at end of file

--
Gitblit v1.9.3