From a1272018d3c8d0b5a520ab53588518122f6b5bf6 Mon Sep 17 00:00:00 2001
From: 南骏 池 <chiffly@163.com>
Date: 星期六, 15 二月 2025 14:26:06 +0800
Subject: [PATCH] 1.生产报工界面交互优化 2.其他入库界面交互优化

---
 H5/Js/Qtrk.js |   27 +++++++++++++++++++++------
 1 files changed, 21 insertions(+), 6 deletions(-)

diff --git a/H5/Js/Qtrk.js b/H5/Js/Qtrk.js
index e095587..5ba8212 100644
--- a/H5/Js/Qtrk.js
+++ b/H5/Js/Qtrk.js
@@ -95,12 +95,20 @@
                     console.log(error);
                 });
         },
-        getSectionCode(value) {
+        getSectionCode() {
             var that = this;
-            that.sectionCode = value;
+            //that.sectionCode = value;
 
-            if (!that.barcode) {
-                this.$toast.fail("鏉$爜涓嶈兘涓虹┖");
+            //if (!that.barcode) {
+            //    this.$toast.fail("鏉$爜涓嶈兘涓虹┖");
+            //    that.isLoading = false;
+            //    return;
+            //}
+
+            if (!that.billNo) {
+                this.$toast.fail("鐢宠鍗曞彿涓嶈兘涓虹┖");
+                that.$refs.sectionCode.focus();
+                that.sectionCode = null;
                 that.isLoading = false;
                 return;
             }
@@ -110,6 +118,7 @@
                 that.isLoading = false;
                 return;
             }
+
             that.AxiosHttp("post", 'MesItemQtrk/ScanInDepotsQT', {
                 billNo: that.billNo,
                 sectionCode: that.sectionCode
@@ -118,9 +127,12 @@
                     var json = res;
                     if (json.status == 0) {
                         that.$notify({ type: 'success', message: json.data.tbBillList });
+                        that.$refs.barcode.focus();
                     }
                     else {
                         that.$toast.fail(json.message);
+                        that.$refs.sectionCode.focus();
+                        that.sectionCode = null;
                     }
                     that.isLoading = false;
                 })
@@ -130,9 +142,9 @@
                     console.log(error);
                 });
         },
-        getBarcode(value) {
+        getBarcode() {
 
-            this.barcode = value;
+            //this.barcode = value;
 
             var that = this;
             that.isLoading = true;
@@ -177,10 +189,13 @@
                         that.barcode = null;
                         that.ItemBlDetail = json.data.items;
                         that.$notify({ type: 'success', message: '鎵弿鎴愬姛' });
+                        that.$refs.barcode.focus();
                         //that.GetMesItemBlDetailByBillNo()
                     }
                     else {
                         that.$toast.fail(json.message);
+                        that.$refs.barcode.focus();
+                        that.barcode = null;
                     }
                     that.isLoading = false;
                 })

--
Gitblit v1.9.3