From 3537cc6a8483e85c377da86c54f2f5b2ef4852ea Mon Sep 17 00:00:00 2001 From: lilili Date: Tue, 4 Jul 2023 10:25:28 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E6=89=B9=E9=87=8F=E6=89=93?= =?UTF-8?q?=E5=8D=B0=E6=9D=A1=E7=A0=81=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../WMSCreateItemLot/CreateItemLot.cshtml | 116 +++--------------- 1 file changed, 16 insertions(+), 100 deletions(-) diff --git a/WMS-BS/NFine.Web/Areas/WMS/Views/WMSCreateItemLot/CreateItemLot.cshtml b/WMS-BS/NFine.Web/Areas/WMS/Views/WMSCreateItemLot/CreateItemLot.cshtml index 8579400..6c22659 100644 --- a/WMS-BS/NFine.Web/Areas/WMS/Views/WMSCreateItemLot/CreateItemLot.cshtml +++ b/WMS-BS/NFine.Web/Areas/WMS/Views/WMSCreateItemLot/CreateItemLot.cshtml @@ -1839,7 +1839,7 @@ viewrecords: true, multiselect: true, beforeSelectRow: function (rowid, e) { - + warehouse }, subGrid: true, // (1)开启子表格支持 subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数 @@ -3292,107 +3292,22 @@ var mold = ''; var objArr = ''; var arr = []; - var obj = $("#gridList").jqGrid("getRowData"); - if (Type == '1') { mold = '00001'; }//生产退料生成条码 - if (Type == '2') { mold = '00002'; }//委外退料生成条码 - if (Type == '3') { - mold = '00003'; - for (var i = 0; i < obj.length; i++) { - var $SubGird = $("#gridList_" + obj[i].ID + "_t"); - var rowData = $SubGird.jqGrid('getGridParam', 'selarrrow'); - if (rowData != "undefined" && rowData != null) { - for (var j = 0; j < rowData.length; j++) { - objArr += "'" + rowData[j] + "',"; - } - objArr = objArr.slice(0, objArr.length - 1); - objArr = "" + objArr + "|"; - arr.push(objArr); - } - } - }//工单成品生成条码 - if (Type == '4') { - mold = '00004'; - for (var i = 0; i < obj.length; i++) { - var $SubGird = $("#gridList_" + obj[i].ID + "_t"); - var rowData = $SubGird.jqGrid('getGridParam', 'selarrrow'); - if (rowData != "undefined" && rowData != null) { - for (var j = 0; j < rowData.length; j++) { - objArr += "'" + rowData[j] + "',"; - } - objArr = objArr.slice(0, objArr.length - 1); - objArr = "" + objArr + "|"; - arr.push(objArr); - } - } - }//销售退货生成条码 - if (Type == '5') { - mold = '00005'; - for (var i = 0; i < obj.length; i++) { - var $SubGird = $("#gridList_" + obj[i].ID + "_t"); - var rowData = $SubGird.jqGrid('getGridParam', 'selarrrow'); - if (rowData != "undefined" && rowData != null) { - for (var j = 0; j < rowData.length; j++) { - objArr += "'" + rowData[j] + "',"; - } - objArr = objArr.slice(0, objArr.length - 1); - objArr = "" + objArr + "|"; - arr.push(objArr); - } - } - }//其他入库生成条码 - if (Type == '6') { mold = '00006'; }//归还单生成条码 - if (Type == '7') { + var obj = $("#gridList").jqGrid('getGridParam', 'selarrrow'); mold = '00007'; - for (var i = 0; i < obj.length; i++) { - var $SubGird = $("#gridList_" + obj[i].ID + "_t"); - var rowData = $SubGird.jqGrid('getGridParam', 'selarrrow'); - if (rowData != "undefined" && rowData != null) { - for (var j = 0; j < rowData.length; j++) { - objArr += "'" + rowData[j] + "',"; - } - objArr = objArr.slice(0, objArr.length - 1); - objArr = "" + objArr + "|"; - arr.push(objArr); - } - } - }//普通到货单生成条码 - if (Type == '8') { mold = '00008'; }//委外到货单生成条码 - if (Type == '9') { - mold = '00009'; - for (var i = 0; i < obj.length; i++) { - var $SubGird = $("#gridList_" + obj[i].ID + "_t"); - var rowData = $SubGird.jqGrid('getGridParam', 'selarrrow'); - if (rowData != "undefined" && rowData != null) { - for (var j = 0; j < rowData.length; j++) { - objArr += "'" + rowData[j] + "',"; - } - objArr = objArr.slice(0, objArr.length - 1); - objArr = "" + objArr + "|"; - arr.push(objArr); - } - } - }//成品入库单生成条码 - if (Type == '10') { mold = '00010'; }//拒收单生成条码 - if (Type == '11') { mold = '00011'; }//委外拒收单生成条码 - if (Type == '12') { - mold = '00012'; - for (var i = 0; i < obj.length; i++) { - var $SubGird = $("#gridList_" + obj[i].ID + "_t"); - var rowData = $SubGird.jqGrid('getGridParam', 'selarrrow'); - if (rowData != "undefined" && rowData != null) { - for (var j = 0; j < rowData.length; j++) { - objArr += "'" + rowData[j] + "',"; - } - objArr = objArr.slice(0, objArr.length - 1); - objArr = "" + objArr + "|"; - arr.push(objArr); - } + for (var i = 0; i < obj.length; i++) { + var rowId = obj[i]; + var rowData = $("#gridList").jqGrid('getRowData', rowId); + if (rowData != "undefined" && rowData != null) { + objArr += "'" + rowId + "',"; + objArr = objArr.slice(0, objArr.length - 1); + objArr = "" + objArr + "|"; + arr.push(objArr); } - }//领料申请退料 - if (Type == '13') { mold = '00013'; }//材料出库退料 - if (Type == '14') { mold = '00014'; }//委外领料申请退料 - if (Type == '15') { mold = '00015'; }//委外材料出库退料 - if (Type == '16') { mold = '00016'; }//返工工单 + } + if (objArr == "") { + $.modalAlertNew("WMS00101"); + return; + } $.modalOpen({ id: "PrintLot", title: "打印", @@ -3697,6 +3612,7 @@ 批量入库 删除条码 打印 + 批量打印