From 6a55acb53f6a8c398f4e6dc4a04ab7d7f49d5b0a Mon Sep 17 00:00:00 2001
From: wangyi <2946747746@qq.com>
Date: 星期四, 12 三月 2026 19:43:29 +0800
Subject: [PATCH] .金蝶云跳转的条码生成页面,增加按钮 查看本单生成条码,跳转到条码档案(优化)

---
 src/views/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong_AutoLogin.vue |   87 +++++++++++++++++++++----------------------
 1 files changed, 42 insertions(+), 45 deletions(-)

diff --git a/src/views/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong_AutoLogin.vue b/src/views/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong_AutoLogin.vue
index bd485d0..5c3d836 100644
--- a/src/views/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong_AutoLogin.vue
+++ b/src/views/warehouse/barcodeMaster/Gy_BarCodeBill_JinLong_AutoLogin.vue
@@ -1,6 +1,6 @@
 <template>
     <div style="margin: 10px;">
-        <div style=" margin-bottom: 10px; border-bottom: 1px solid #f6f6f6;"get_BarCodeBillList>
+        <div style=" margin-bottom: 10px; border-bottom: 1px solid #f6f6f6;">
             <el-button type="primary" @click="onClickMethod_BarCodeProduce" :disabled="disabledFlag_BarCodeProduce">鐢熸垚</el-button>
             <el-button type="primary" @click="get_PrintReport">鎵撳嵃</el-button>
             <el-button type="primary" @click="get_BarCodeBillList">鏉$爜妗f</el-button>
@@ -164,7 +164,7 @@
                 </el-tab-pane>
             </el-tabs>
         </el-form>
-
+        
         <!-- 鎵撳嵃寮圭獥 -->
         <el-dialog title="鎵撳嵃妯℃澘閫夋嫨" :visible.sync="openPrintList" width="800px" append-to-body>
             <PrintList :linterid="rowSel.toString()" :MyMsg="rowSel.toString()" Type="HGy_BarCodeBill"
@@ -188,7 +188,7 @@
         return {
             baseURL: process.env.VUE_APP_BASE_API,                      //鍚庣鎺ュ彛璁块棶鍓嶇紑
             HModName: "Gy_BarCodeBill_JinLong_AutoLogin",               //妯″潡鍚嶇О
-            disabledFlag_BarCodeProduce:false,                          //绂佺敤鏍囪-鐢熸垚 鎸夐挳
+            disabledFlag_BarCodeProduce:false,                          //绂佺敤鏍囪-鐢熸垚 鎸夐挳                                             // iframe URL
             rules:{                                                     //琛ㄥごform 鏍¢獙
 
             },
@@ -570,24 +570,31 @@
         },
         //#endregion
         
-        //#region 鏉$爜琛屽彿鏌ヨ鎸夐挳鐐瑰嚮浜嬩欢
-        async get_BarCodeBillHSEQ(){
-            var params = this.get_UrlVars();
-            var HSourceInterID = params[params[1]];  
-            var HSourceEntryID = params[params[2]];  
-            var HSourceBillNo =  params[params[4]];  
-            var res1 = await this.getPushSource_POInStockBillInit2(HSourceEntryID);
-            var temp = res1.data.data[0];
-            var dataArray = [temp];
-            sessionStorage["HAutoLogin"] = "2";
-            sessionStorage["HMainSourceBillNo"] = HSourceBillNo;
-            sessionStorage["HSourceBillSEQ"] = dataArray[0].HSEQ;
-            this.$router.push({ 
-                path: "/warehouse/barcodeMaster/Gy_BarCodeBillList_JinLong_AutoLogin" 
-            }).catch(() => { });
-           
+  
+         //#region涓嬫帹鐢熸垚鏉$爜
+        async get_BarCodeBillHSEQ() {
+                var params = this.get_UrlVars();
+                var HSourceInterID = params[params[1]];  
+                var HSourceEntryID = params[params[2]];  
+                var res1 = await this.getPushSource_POInStockBillInit1(HSourceInterID,HSourceEntryID);
+                var temp = res1.data.data[0];
+                var dataArray = [temp];
+                var HSEQ 
+                if (dataArray && dataArray.length > 0 && dataArray[0]) {
+                    if (dataArray[0].HSEQ == '') {
+                        HSEQ = 0;
+                    } else {
+                        HSEQ = dataArray[0].HSEQ;
+                    }
+                } else {
+                    HSEQ = 0; 
+                }
+                this.$router.push({ 
+               path: `/warehouse/barcodeMaster/Gy_BarCodeBillList_JinLong_AutoLogin?OperationType=4&HSourceInterID=${HSourceInterID}&HSourceEntryID=${HSourceEntryID}&HSEQ=${HSEQ}` 
+               }).catch(() => { });
         },
-        //#endregion
+
+          //#endregion
 
         //#region 鏉$爜鍒楄〃澶嶉�夋閫夋嫨鐘舵�佸彉鏇寸洃鍚簨浠�
         onSelectionChange_BarCode(selection){
@@ -623,35 +630,25 @@
             })
         },
         //#endregion
-        //#region 鏍规嵁涓诲唴鐮佷笌瀛愬唴鐮佽幏鍙栨簮鍗曟敹鏂欓�氱煡鍗曟暟鎹�
-        async getPushSource_POInStockBillInit2(HSourceEntryID) {
-            var res = "none";
-            var sql = "select * from Cg_POInStockBillSub where 1=1 and  HEntryID = " + HSourceEntryID;
+       //#region 鏍规嵁涓诲唴鐮佷笌瀛愬唴鐮佽幏鍙栨簮鍗曟敹鏂欓�氱煡鍗曟暟鎹紙鍚堝苟鐗堬級
+        async getPushSource_POInStockBillInit1(HSourceInterID, HSourceEntryID) {
+            var sql = `SELECT m.*, s.* 
+                    FROM Cg_POInStockBillMain m
+                    INNER JOIN Cg_POInStockBillSub s ON m.hinterid = s.HInterID
+                    WHERE 1=1`;
+            sql += ` AND m.hinterid = ${HSourceInterID}`;
+            sql += ` AND s.HEntryID = ${HSourceEntryID}`;
             var ModRightNameCheck = "";
             return axios.get(this.$baseUrl + '/CommonModel/searchMethod', {
-                async:false,
                 params: {
-                    "sql": sql
-                    , "user": sessionStorage["HUserName"]
-                    , "ModRightNameCheck": ModRightNameCheck
+                    "sql": sql,
+                    "user": sessionStorage["HUserName"],
+                    "ModRightNameCheck": ModRightNameCheck
                 },
             })
         },
         //#endregion
-        //#region 鏍规嵁琛ㄧ殑涓昏〃鍐呯爜鏌ヨ琛ㄤ腑鏁版嵁
-        async getPushSource_POInStockBillInit1(HSourceInterID) {
-            var res = "none";
-            var sql = "select * from Cg_POInStockBillMain where 1=1 and hinterid = " + HSourceInterID ;
-            var ModRightNameCheck = "";
-            return axios.get(this.$baseUrl + '/CommonModel/searchMethod', {
-                async:false,
-                params: {
-                    "sql": sql
-                    , "user": sessionStorage["HUserName"]
-                    , "ModRightNameCheck": ModRightNameCheck
-                },
-            })
-        },
+
         //#endregion
     
         //#region 涓嬫帹椤甸潰鍒濆鍖�
@@ -669,11 +666,11 @@
             var res  = "none"
             var res1 = "none"
             try{
-                res = await this.getPushSource_POInStockBillInit(HSourceInterID, HSourceEntryID);
-                res1 = await this.getPushSource_POInStockBillInit1(HSourceInterID);  
+                res1 = await this.getPushSource_POInStockBillInit1(HSourceInterID,HSourceEntryID);  
                 if(res1.data.data.length<=0){
-                    this.$modal.msgError("閲戣澏浜戜腑鐨勬暟鎹湭鍚屾锛岃妫�鏌ユ敹鏂欓�氱煡鍗曟槸鍚﹀鏍�");
+                    this.$modal.msgError("褰撳墠鍗曟嵁鏈悓姝ワ紝璇疯繑鍥為噾铦朵簯SRM骞冲彴閫佽揣鍗曞垪琛ㄦ壘鍒拌鍗曟嵁鍦ㄦ煡鐪嬮〉闈㈢偣鍑汇�愪紶閫扺MS銆戞寜閽紒锛�");
                 }else{
+                    res = await this.getPushSource_POInStockBillInit(HSourceInterID, HSourceEntryID);
                     if(res.data.code=="1"){
                         if(res.data.data.length>0){
                             res = await this.getPushSource_POInStockBillInit(HSourceInterID, HSourceEntryID);

--
Gitblit v1.9.1