From 3e049efc6eb3970bb200058e41468f0a38de1a7e Mon Sep 17 00:00:00 2001
From: chenhaozhe <cgz@hz-kingdee.com>
Date: 星期二, 20 一月 2026 16:14:09 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-VUEUI

---
 src/views/warehouse/barcodeMaster/Gy_BarCodeBillList.vue |  117 ++++++++++++++++++++++++++++++++++++++++++++++++++++------
 1 files changed, 105 insertions(+), 12 deletions(-)

diff --git a/src/views/warehouse/barcodeMaster/Gy_BarCodeBillList.vue b/src/views/warehouse/barcodeMaster/Gy_BarCodeBillList.vue
index ae933a5..f4535ed 100644
--- a/src/views/warehouse/barcodeMaster/Gy_BarCodeBillList.vue
+++ b/src/views/warehouse/barcodeMaster/Gy_BarCodeBillList.vue
@@ -114,8 +114,24 @@
       </el-collapse>
     </el-form>
     <el-row :gutter="10" class="mb8" style="margin-top: 10px;">
+      <!-- <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-delete" size="mini" :disabled="single" @click="handleDrop">鍒犻櫎
+        </el-button>
+      </el-col> -->
       <el-col :span="1.5">
-        <el-button type="primary" icon="el-icon-delete" size="mini" :disabled="single" @click="handleDelete">鍒犻櫎
+        <el-button type="primary" icon="el-icon-delete" size="mini" :disabled="single" @click="handleDelete(0)">浣滃簾
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-delete" size="mini" :disabled="single" @click="handleDelete(1)">鍙嶄綔搴�
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-delete" size="mini" @click="handleBatchDelete(0)">鎵归噺浣滃簾
+        </el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button type="primary" icon="el-icon-delete" size="mini" @click="handleBatchDelete(1)">鎵归噺鍙嶄綔搴�
         </el-button>
       </el-col>
       <el-col :span="1.5">
@@ -161,8 +177,8 @@
       </el-dialog>
       <!-- 鎵撳嵃 -->
       <el-dialog title="鎵撳嵃妯℃澘閫夋嫨" :visible.sync="openPrintList" width="800px" append-to-body>
-        <PrintList :linterid="rowSel.toString()" :MyMsg="rowSel.toString()" Type="HGy_BarCodeBillList"
-          HModName="HGy_BarCodeBillList" @rowEditClose="rowSetClose" v-if="printListShow" />
+        <PrintList :linterid="rowSel.toString()" :MyMsg="rowSel.toString()" Type="HGy_BarCodeBill"
+          HModName="HGy_BarCodeBill" @rowEditClose="rowSetClose" v-if="printListShow" />
       </el-dialog>
     </div>
   </div>
@@ -182,7 +198,6 @@
       baseURL: process.env.VUE_APP_BASE_API,                //鍚庣鎺ュ彛鍓嶇紑(鍚庣鏈嶅姟鍣╥p鍦板潃)
 
       HInterID: null,
-      checkDataList: [],                                    //琛ㄦ牸閫変腑鏁版嵁闆嗗悎
       rowSel: [],                                           //鐢ㄤ簬鎵撳嵃鐨勬暟鎹泦鍚�
       
       rqsgList: [                                           //鏃ユ湡闂撮殧涓嬫媺鍒楄〃鏁版嵁
@@ -262,6 +277,7 @@
       lastSelectedRow: null,                                        // 涓婁竴娆¢�変腑鐨勮
       selectedRow: null,                                            // 褰撳墠閫変腑鐨勮
       rowForm: {},                                                  // 褰撻�変腑鐨勫彧鏈変竴琛屾椂锛屾洿鏂版暟鎹负璇ラ�変腑鐨勮銆�
+      checkDataList: [],                                            // 琛ㄦ牸閫変腑鏁版嵁闆嗗悎
 
       tyResList: [],                                                // 鍒楄〃鏁版嵁锛岀敤浜庡鍑�
       titleData: [],                                                // 涓嶉渶瑕佹樉绀虹殑瀛楁 鍙墿灞�
@@ -312,7 +328,7 @@
     //#region 澶氶�夋閫変腑鏁版嵁
     handleSelectionChange(selection) {
       // this.rowForm = {}
-      checkDataList = selection;
+      this.checkDataList = selection;
       this.ids = selection.map(item => item.hmainid)
       this.single = selection.length != 1
       this.multiple = !selection.length
@@ -340,7 +356,7 @@
     
     //#region 鍔犺浇缁勭粐涓嬫媺鍒楄〃鏁版嵁
     fetchData() {
-      axios.get(this.baseURL + "/Web/GetOrganizations", {
+      axios.get(this.$baseUrl + "/Web/GetOrganizations", {
       }).then(response => {
         if (response.data.count == 1) {
           this.organizationList = response.data.data;//缁勭粐鍒楄〃
@@ -454,7 +470,7 @@
       if (this.queryParams.HBarCode) {
         this.sWhere += " and 鏉$爜缂栧彿 like ''%" + this.queryParams.HBarCode + "%''";
       }
-      if (this.queryParams.HSupName) {
+      if (this.queryParams.HSourceBillNo) {
         this.sWhere += " and 婧愬崟鍗曞彿 like ''%" + this.queryParams.HSourceBillNo + "%''";
       }
       if (this.queryParams.HMaterNumber) {
@@ -466,6 +482,12 @@
       if (this.queryParams.HOrgID) {
         this.sWhere += " and HStockOrgID = ''" + this.queryParams.HOrgID + "''";
       }
+
+      //濡傛灉鏄嚜鍔ㄧ櫥褰曪紝鍒欏彧鑳芥煡鐪嬩緵搴斿晢鑷繁鐨勬潯鐮併��
+      if (sessionStorage["HAutoLogin"] == "1") {
+        this.sWhere += " and HSupID = ''" + sessionStorage["HUserName"] + "''";
+      }
+
       this.getList()
     },
     //#endregion
@@ -480,7 +502,7 @@
       this.loading = true
       
       // 鍒楄〃鏌ヨ
-      axios.get(this.baseURL + '/Gy_BarCodeBillList/page', {
+      axios.get(this.$baseUrl + '/Gy_BarCodeBillList/page', {
         params: {
           "sWhere": this.sWhere,
           "user": sessionStorage["HUserName"],
@@ -518,6 +540,7 @@
           option.data = data1.data;
           var result = data1.data;
           option.data = result;
+          this.checkDataList = [];
           let HModName = "Gy_BarCodeBillList"
           this.DisPlay_HideColumn(HModName, sessionStorage["HUserName"], option, this.dataList);
         }
@@ -559,7 +582,77 @@
     //#endregion
 
     //#region 鍒犻櫎
-    handleDelete() {
+    handleDrop() {
+    },
+    //#endregion
+
+    //#region 浣滃簾
+    handleDelete(num) {
+      if (this.checkDataList.length != 1) {
+        this.$modal.msgError("璇烽�夋嫨涓�琛屾暟鎹�");
+      } else {
+        // this.rowSel = [];
+        // for (var i = 0; i < this.checkDataList.length; i++) {
+        //   this.rowSel.push(this.checkDataList[i].HItemID.toString());
+        // }
+
+        var HInterID = this.checkDataList[0].HItemID;
+        // 鍒楄〃鏌ヨ
+        axios.get(this.$baseUrl + '/Gy_BarCodeBillList/DeleteGy_BarCodeBillList', {
+          params: {
+            "HInterID": HInterID,
+            "IsAudit": num,
+            "CurUserName": sessionStorage["HUserName"],
+          },
+        }).then(response => {
+          let data1 = response.data
+          if (data1.count == 1) {
+            this.handleQuery();
+          }else{
+            this.$modal.msgError(data1.Message);
+          }
+        }).catch(error => {
+          this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+        });
+      }
+    },
+    //#endregion
+
+    //#region 鎵归噺浣滃簾
+    handleBatchDelete(num) {
+      if (this.checkDataList.length == 0) {
+        this.$modal.msgError("璇烽�夋嫨鏁版嵁");
+      } 
+      else if(this.checkDataList.length >100){
+        this.$modal.msgError("閫夋嫨鏁版嵁涓嶅彲澶т簬100鏉★紒");
+      }
+      else {
+        var HInterIDListStr = "";
+        for(var i=0;i<this.checkDataList.length;i++){
+          if(i==this.checkDataList.length-1){
+            HInterIDListStr += this.checkDataList[i].hmainid.toString();
+          }else{
+            HInterIDListStr += this.checkDataList[i].hmainid.toString() + ",";
+          }
+        }
+        // 鍒楄〃鏌ヨ
+        axios.get(this.$baseUrl + '/Gy_BarCodeBillList/DeleteBatchGy_BarCodeBillList', {
+          params: {
+            "HInterID": HInterIDListStr,
+            "IsAudit": num,
+            "CurUserName": sessionStorage["HUserName"],
+          },
+        }).then(response => {
+          let data1 = response.data
+          if (data1.count == 1) {
+            this.handleQuery();
+          }else{
+            this.$modal.msgError(data1.Message);
+          }
+        }).catch(error => {
+          this.$modal.msgError("鎺ュ彛璇锋眰澶辫触!");
+        });
+      }
     },
     //#endregion
 
@@ -576,7 +669,7 @@
     },
     DisPlay_HideColumn(HModName, user, option, dataOption) {
       this.totalNameList = []
-      axios.get(this.baseURL + '/Xt_grdAlignment_WMES/grdAlignmentWMESList', {
+      axios.get(this.$baseUrl + '/Xt_grdAlignment_WMES/grdAlignmentWMESList', {
         params: {
           "HModName": HModName,
           "user": user,
@@ -727,8 +820,8 @@
        this.$modal.msgError("璇烽�夋嫨鏁版嵁");
       } else {
         this.rowSel = [];
-        for (var i = 0; i < this.selection.length; i++) {
-          this.rowSel.push(this.selection[i].HItemID.toString());
+        for (var i = 0; i < this.checkDataList.length; i++) {
+          this.rowSel.push(this.checkDataList[i].HItemID.toString());
         }
         this.printListShow = true;
         this.openPrintList = true;

--
Gitblit v1.9.1