From ebd9bda7e25c054edccba6854bb1171b758a7ace Mon Sep 17 00:00:00 2001
From: yusijie <ysj@hz-kingdee.com>
Date: 星期一, 29 十二月 2025 12:56:43 +0800
Subject: [PATCH] 香囊标签打印过站优化

---
 WebTM/views/车间管理/单品过站_小卫/Cj_SachetBarCodePrint.html |   36 ++++++++++++++++++------------------
 1 files changed, 18 insertions(+), 18 deletions(-)

diff --git "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\215\225\345\223\201\350\277\207\347\253\231_\345\260\217\345\215\253/Cj_SachetBarCodePrint.html" "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\215\225\345\223\201\350\277\207\347\253\231_\345\260\217\345\215\253/Cj_SachetBarCodePrint.html"
index 05f91da..111cff2 100644
--- "a/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\215\225\345\223\201\350\277\207\347\253\231_\345\260\217\345\215\253/Cj_SachetBarCodePrint.html"
+++ "b/WebTM/views/\350\275\246\351\227\264\347\256\241\347\220\206/\345\215\225\345\223\201\350\277\207\347\253\231_\345\260\217\345\215\253/Cj_SachetBarCodePrint.html"
@@ -351,7 +351,7 @@
 
                                 //鑷姩鎵撳嵃
                                 if (option.data.length > 0) {
-                                    get_BatchPrint();
+                                    get_BatchPrint(HICMOInterID, HICMOEntryID);
                                 }                                
                             }
                             else {
@@ -369,18 +369,18 @@
             //鎵归噺鎵撳嵃
             var time;
             var num = 0;
-            function get_BatchPrint() {
+            function get_BatchPrint(HICMOInterID, HICMOEntryID) {
                 //鎵撳嵃闂撮殧
                 var HTime = $("#HTime").val();
 
                 time = setInterval(function () {
-                    dy_PL(option.data);
+                    dy_PL(HICMOInterID, HICMOEntryID, option.data);
                 }, HTime*1000);
             }
 
-            function dy_PL(rest) {
-                var HItemID = rest[num].HBarCodeID.toString();
-                var sWhere = "select top 1 HBarCode 鏉$爜缂栧彿,isnull(ms.HCusRelationNumber,'') SKU from Gy_BarCodeBill a with(nolock) left join Gy_Material m with(nolock) on a.HMaterID = m.HItemID left join Gy_MateNumRelation_Sec ms with(nolock) on m.HMASTERID = ms.HMaterID where a.HItemID = " + HItemID
+            function dy_PL(HICMOInterID, HICMOEntryID,rest) {
+                //var HItemID = rest[num].HBarCodeID.toString();
+                var sWhere = "select top 1 a.HItemID,HBarCode 鏉$爜缂栧彿,isnull(ms.HCusRelationNumber,'') SKU from Gy_BarCodeBill a with(nolock) left join Gy_Material m with(nolock) on a.HMaterID = m.HItemID left join Gy_MateNumRelation_Sec ms with(nolock) on m.HMASTERID = ms.HMaterID where a.HSourceInterID = " + HICMOInterID + " and a.HSourceEntryID = " + HICMOEntryID + " and a.HPrintQty = 0 order by a.HItemID asc";
 
                 $.ajax({
                     type: "GET",
@@ -427,18 +427,18 @@
                                     num++;
                                 }
 
-                                //var sql = "update a set HPrintQty = HPrintQty + 1 from Gy_BarCodeBill a with(nolock) where HItemID = " + HInterID ;
-                                //$.ajax({
-                                //    type: "GET",
-                                //    url: GetWEBURL() + "/Gy_SOPBillList/UpDelSQL", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
-                                //    async: false,
-                                //    data: { "sWhere": sql },
-                                //    success: function (result) {
-                                //        if (result.data.code != 1) {
-                                //            layer.alert("鏇存柊鎵撳嵃鏃ユ湡寮傚父锛�" + result.data.Message);
-                                //        }
-                                //    }
-                                //})
+                                var sql = "update a set HPrintQty = HPrintQty + 1 from Gy_BarCodeBill a with(nolock) where HItemID = " + data.data[0].HItemID;
+                                $.ajax({
+                                    type: "GET",
+                                    url: GetWEBURL() + "/Gy_SOPBillList/UpDelSQL", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+                                    async: false,
+                                    data: { "sWhere": sql },
+                                    success: function (result) {
+                                        //if (result.data.code != 1) {
+                                        //    layer.alert("鏇存柊鎵撳嵃鏃ユ湡寮傚父锛�" + result.data.Message);
+                                        //}
+                                    }
+                                })
 
                             } else {
                                 layer.msg("鏌ユ棤鏁版嵁!");

--
Gitblit v1.9.1