From 603670bfbc029fd081fb1c88d00a18f78ec7d349 Mon Sep 17 00:00:00 2001
From: 南骏 池 <chiffly@163.com>
Date: 星期三, 02 四月 2025 14:26:57 +0800
Subject: [PATCH] 1.采购入库界面优化

---
 H5/Js/PurchaseInventory.js |   34 ++++++++++++++++++++--------------
 1 files changed, 20 insertions(+), 14 deletions(-)

diff --git a/H5/Js/PurchaseInventory.js b/H5/Js/PurchaseInventory.js
index f535e6e..060010e 100644
--- a/H5/Js/PurchaseInventory.js
+++ b/H5/Js/PurchaseInventory.js
@@ -31,6 +31,9 @@
             contentScrollW: 0, // 瀵艰埅鍖哄搴�
             scrollLeft: 0, // 妯悜婊氬姩鏉′綅缃�
             fullHeight: "",
+            sectionCode:"",
+            depotData: [],
+            ItemDetail: [],
         }
     },
     mounted() {
@@ -45,25 +48,27 @@
             var that = this;
             that.isLoading = true;
             that.AxiosHttp("post", 'MesDepotSections/GetSectionName', {
-                sectionCode: that.formData.sectionCode
+                sectionCode: that.sectionCode
             }, false)
                 .then(function (res) {
                     var json = res;
                     if (json.status == 0) {
-                        that.formData.sectionName = json.data.tbBillList;
+                        that.depotData = json.data.tbBillList;
                         that.$refs.barcode.focus();
                     }
                     else {
                         that.$toast.fail(json.message);
-                        that.formData.sectionName = "";
+                        that.depotData = [];
+                        that.sectionCode = "";
                     }
                     that.isLoading = false;
                 })
                 .catch(function (error) {
                     that.isLoading = false;
                     that.$toast.fail("缃戠粶閿欒锛岃閲嶈瘯锛�");
-                    console.log(error);
-                    that.$refs.daa001.focus();
+                    that.depotData = [];
+                    that.sectionCode = "";
+                    that.$refs.sectionCode.focus();
                 });
         },
         getScan() {
@@ -71,20 +76,20 @@
              
             that.isLoading = true;
             that.AxiosHttp("post", 'MesInvItemInCDetails/SaveBarCodes', {
-                sectionCode: that.formData.sectionCode,
+                sectionCode: that.sectionCode,
                 userName: that.userInfo.loginAccount,
                 barcode: that.formData.barcode,
             }, false)
                 .then(function (res) {
                     var json = res;
                     if (json.status == 0) {
-                        that.formData.itemNo = json.data.tbBillList.itemNo;
-                        that.formData.sumQuantity = json.data.tbBillList.sumQuantity;
-
-                        that.itemInsFormData = json.data.tbBillList.itemIns;
-                        that.itemTableData = json.data.tbBillList.itemInDetails;
-                        that.tableData = json.data.tbBillList.invItemInCDetails;
-                        that.barMessage = json.data.tbBillList.message;
+                        //that.formData.itemNo = json.data.tbBillList.itemNo;
+                        //that.formData.sumQuantity = json.data.tbBillList.sumQuantity;
+                        that.ItemDetail = json.data.tbBillList.itemInDetails;
+                        //that.itemInsFormData = json.data.tbBillList.itemIns;
+                        //that.itemTableData = json.data.tbBillList.itemInDetails;g
+                        that.tableData = json.data.tbBillList.itemBarCDetails;
+                        //that.barMessage = json.data.tbBillList.message;
                         that.$refs.barcode.focus();
                         that.formData.barcode = null;
                     }
@@ -140,7 +145,8 @@
                 });
         },
         cleraCode() {
-            this.formData.sectionCode = null;
+            this.sectionCode = "";
+            this.$refs.sectionCode.focus();
         },
         ToErp() {
             this.Message = "";

--
Gitblit v1.9.3