| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">批次号</label> |
| | | <label class="layui-form-label">进厂编号</label> |
| | | <div class="layui-input-inline"> |
| | | <input type="text" id="LotNo" name="LotNo" placeholder="批次号" |
| | | <input type="text" id="LotNo" name="LotNo" placeholder="进厂编号" |
| | | autocomplete="off" class="layui-input"> |
| | | </div> |
| | | </div> |
| | |
| | | <div class="layui-input-inline" style="width: 220px;"> |
| | | <select name="PickingArea" id="PickingArea" lay-search> |
| | | <option value=""></option> |
| | | <option value="1">1</option> |
| | | <option value="2">2</option> |
| | | <option value="3">3</option> |
| | | <option value="4">4</option> |
| | | <option value="033">033</option> |
| | | <option value="039">039</option> |
| | | <option value="044">044</option> |
| | | <option value="051">051</option> |
| | | <option value="059">059</option> |
| | | </select> |
| | | </div> |
| | | </div> |
| | |
| | | var html = ''; |
| | | if(d.IsWave == '0'){ |
| | | if(d.Status == '0' || d.Status == '1' ){ |
| | | if(d.Type != "8") { |
| | | if(d.Type != "8" && d.Type != "2" && d.Type != "3") { |
| | | html += `<a class="layui-btn layui-btn-normal layui-btn-xs zifenClass" lay-event="auto"> |
| | | <i class="layui-icon layui-icon-ok"></i>自动分配 |
| | | </a>`; |
| | |
| | | <script type="text/html" id="table-content-list2"> |
| | | {{# function GetBtn2(d){ |
| | | var html = ''; |
| | | |
| | | if((d.StatusZ == "2" || d.StatusZ == "3"|| d.StatusZ == "4") && (d.Type == "1" || d.Type == "2" || d.Type == "3") && d.IsWave == "0"){ |
| | | html += `<a class="layui-btn layui-btn-normal layui-btn-xs shoufenClass" lay-event="wan"> |
| | | <i class="layui-icon layui-icon-ok"></i>手动分配 |
| | | </a>`; |
| | | } |
| | | if((d.Status == "0" ||d.Status == "1") && d.Qty > d.AllotQty && d.IsWave == "0"){ |
| | | html += `<a class="layui-btn layui-btn-normal layui-btn-xs shoufenClass" lay-event="wan"> |
| | | <i class="layui-icon layui-icon-ok"></i>手动分配 |
| | |
| | | var TotalColsArr = [[ |
| | | {field: '',title: '序号',type:'numbers',width: 50,align: 'center',fixed: 'left', "disabled": true}, |
| | | {field: 'SONo',title: '出库单号',align: 'center',fixed: 'left',width: 165, "disabled": true}, |
| | | {field: 'Type',title: '单据类型',align: 'center',templet:'#templetType'}, |
| | | {field: 'Type',title: '单据类型',align: 'center',width: 124,templet:'#templetType'}, |
| | | {field: 'Status',title: '执行状态', align: 'center',templet: '#templetStatus'}, |
| | | {field: 'LogisticsName',title: '承运商',align: 'center'}, |
| | | {field: 'CustomerName',title: '客户名称',align: 'center'}, |
| | | {field: 'LotNo',title: '批次号',align: 'center'}, |
| | | {field: 'LotNo',title: '进厂编号',align: 'center'}, |
| | | {field: 'LotNoText',title: '批次描述',align: 'center'}, |
| | | {field: 'IsDespatch',title: '是否发运',align: 'center',templet: '#templetIsDespatch'}, |
| | | {field: 'SupplierLot',title: '供货批次',align: 'center'}, |
| | | {field: 'SupplierLot',title: '原厂批号',align: 'center'}, |
| | | {field: 'Origin',title: '来源',align: 'center'}, |
| | | {field: 'Demo',title: '备注',align: 'center',width: 180}, |
| | | {field: 'CreateUserName',title: '创建人',align: 'center'}, |
| | |
| | | var TotalColsSysArr=encodeURIComponent(encodeURIComponent(JSON.stringify(TotalColsArr)))//将表头数据进行url编码 |
| | | //#endregion |
| | | function refreshTable() { |
| | | //#region 原始非自定义列 |
| | | // var param = { |
| | | // No: $("#No").val(), |
| | | // Type: $("#Type").val(), |
| | | // Status: $("#Status").val(), |
| | | // LotNo: $("#LotNo").val(), |
| | | // LogisticsId: parseInt($("#LogisticsId").val()), |
| | | // IsWave: $("#IsWave").val(), |
| | | // IsDespatch: $("#IsDespatch").val(), |
| | | // // WaveNo: $("#WaveNo").val(), |
| | | // }; |
| | | |
| | | // table.render({ |
| | | // elem: '#LAY-app-content-list', |
| | | // url: IP+"/BllSo/GetExportNoticeList", |
| | | // method: 'POST', |
| | | // height: h1 ,//'full-'+hei1 |
| | | // id: 'LAY-app-content-list', |
| | | // where: param, |
| | | // contentType: 'application/json', |
| | | // headers:{ToKen:$.cookie('token')}, |
| | | // page: true, |
| | | // defaultToolbar: ['filter'], //'print', 'exports' |
| | | // even: true, |
| | | // limit: pageCnt, |
| | | // limits: pageLimits, |
| | | // cellMinWidth: 60, //全局定义常规单元格的最小宽度,layui 2.2.1 新增 |
| | | // even:true, |
| | | // done: function(res){ |
| | | // initMenu(); |
| | | // var soCode = "res.data[0].SONo"; |
| | | // if (res.data.length != 0) { |
| | | // soCode = res.data[0].SONo; |
| | | // } |
| | | // refreshTablemx(soCode) |
| | | // }, |
| | | // cols: [ |
| | | // [ { |
| | | // title: '序号', |
| | | // type: 'numbers', |
| | | // width: 65, |
| | | // fixed: 'left', |
| | | // },{ |
| | | // field: 'SONo', |
| | | // title: '出库单号', |
| | | // align: 'center', |
| | | // fixed: 'left', |
| | | // width: 165, |
| | | // },{ |
| | | // field: 'Type', |
| | | // title: '单据类型', |
| | | // align: 'center', |
| | | // // width: 150, |
| | | // templet:function(d){ |
| | | // switch (d.Type) { |
| | | // case "0": |
| | | // return "标准销售出库"; |
| | | // case "1": |
| | | // return "非标准销售出库"; |
| | | // case "2": |
| | | // return "标准调拨出库"; |
| | | // case "3": |
| | | // return "非标准调拨出库"; |
| | | // default: |
| | | // return ""; |
| | | // } |
| | | // } |
| | | // },{ |
| | | // field: 'Status', |
| | | // title: '执行状态', |
| | | // align: 'center', |
| | | // // width: 130, |
| | | // templet: function(d){ |
| | | // switch (d.Status) { |
| | | // case "0": |
| | | // return `<button class="layui-btn layui-btn-radius layui-btn-xs">等待执行</button>`; |
| | | // case "1": |
| | | // return `<button class="layui-btn layui-btn-radius layui-btn-warm layui-btn-xs">部分分配</button>`; |
| | | // case "2": |
| | | // return `<button class="layui-btn layui-btn-radius layui-btn-warm layui-btn-xs">已分配</button>`; |
| | | // case "3": |
| | | // return `<button class="layui-btn layui-btn-radius layui-btn-danger layui-btn-xs">正在执行</button>`; |
| | | // case "4": |
| | | // return `<button class="layui-btn layui-btn-radius layui-btn-normal layui-btn-xs">执行完毕</button>`; |
| | | // case "5": |
| | | // return `<button class="layui-btn layui-btn-radius layui-btn-normal layui-btn-xs">上传完毕</button>`; |
| | | // default: |
| | | // return ""; |
| | | // } |
| | | // } |
| | | // },{ |
| | | // field: 'LogisticsName', |
| | | // title: '承运商', |
| | | // align: 'center', |
| | | // // minWidth: 150 |
| | | // },{ |
| | | // field: 'CustomerName', |
| | | // title: '客户名称', |
| | | // align: 'center', |
| | | // // minwidth: 130 |
| | | // },{ |
| | | // field: 'LotNo', |
| | | // title: '批次号', |
| | | // align: 'center', |
| | | // // width: 180, |
| | | // hide:true |
| | | // },{ |
| | | // field: 'LotNoText', |
| | | // title: '批次描述', |
| | | // align: 'center', |
| | | // // width: 180, |
| | | // hide:true |
| | | // }, |
| | | // // { |
| | | // // field: 'IsWave', |
| | | // // title: '生成波次', |
| | | // // align: 'center', |
| | | // // width: 95, |
| | | // // templet: function (d) { |
| | | // // switch (d.IsWave) { |
| | | // // case "0": |
| | | // // return "否"; |
| | | // // case "1": |
| | | // // return "是"; |
| | | // // default: |
| | | // // return ""; |
| | | // // } |
| | | |
| | | // // }, |
| | | // // }, |
| | | // // { |
| | | // // field: 'WaveNo', |
| | | // // title: '波次单号', |
| | | // // align: 'center', |
| | | // // width: 170 |
| | | // // }, |
| | | // { |
| | | // field: 'IsDespatch', |
| | | // title: '是否发运', |
| | | // align: 'center', |
| | | // // width: 95, |
| | | // templet: function (d) { |
| | | // switch (d.IsDespatch) { |
| | | // case "0": |
| | | // return "否"; |
| | | // case "1": |
| | | // return "是"; |
| | | // default: |
| | | // return ""; |
| | | // } |
| | | |
| | | // }, |
| | | // },{ |
| | | // field: 'SupplierLot', |
| | | // title: '供货批次', |
| | | // align: 'center', |
| | | // // width: 100, |
| | | // hide:true |
| | | // },{ |
| | | // field: 'Origin', |
| | | // title: '来源', |
| | | // align: 'center', |
| | | // // width: 100 |
| | | // },{ |
| | | // field: 'CreateUserName', |
| | | // title: '创建人', |
| | | // align: 'center', |
| | | // // width: 120, |
| | | // },{ |
| | | // field: 'CreateTime', |
| | | // title: '创建时间', |
| | | // align: 'center', |
| | | // // width: 160, |
| | | // templet: function(d) { |
| | | // return formatDate(d.CreateTime); |
| | | // }, |
| | | // },{ |
| | | // field: 'UpdateUserName', |
| | | // title: '修改人', |
| | | // align: 'center', |
| | | // // width: 120, |
| | | // hide:true |
| | | // },{ |
| | | // field: 'UpdateTime', |
| | | // title: '修改时间', |
| | | // align: 'center', |
| | | // // width: 160, |
| | | // templet: function(d) { |
| | | // return formatDate(d.UpdateTime); |
| | | // }, |
| | | // hide:true |
| | | // },{ |
| | | // title: '操作', |
| | | // fixed: 'right', |
| | | // align: 'center', |
| | | // toolbar: '#table-content-list', |
| | | // // width: 240 |
| | | // }] |
| | | // ] |
| | | // }); |
| | | //#endregion |
| | | |
| | | |
| | | //#region 自定义表头 |
| | | var colsJson |
| | | var param1={ |
| | |
| | | //渲染出库单明细 |
| | | //#region 自定义表头 |
| | | var DetailColsArr = [[ |
| | | {field: '',title: '序号',type:'numbers',width: 50,align: 'center',fixed: 'left', "disabled": true}, |
| | | {field: 'SONo',title: '出库单号',align: 'center',fixed: 'left',width:165 }, |
| | | {field: 'SkuNo',title: '物料编码',align: 'center', width: 130}, |
| | | {field: 'SkuName',title: '物料名称',align: 'center', width: 152}, |
| | | {field: 'Standard',title: '物料规格',align: 'center', width: 270}, |
| | | {field: 'LotNo',title: '批次号',align: 'center',width: 150}, |
| | | {field: 'Qty',title: '计划数量',align: 'center',width: 100}, |
| | | {field: 'AllotQty',title: '分配数量',align: 'center',width: 100}, |
| | | {field: 'FactQty',title: '下架数量',align: 'center', width: 100}, |
| | | {field: 'CompleteQty',title: '拣货数量',align: 'center', width: 100}, |
| | | {field: 'IsBale',title: '是否裹包',align: 'center',templet: '#templetIsBale',width: 90}, |
| | | {field: 'IsBelt',title: '是否打带',align: 'center',templet: '#templetIsBelt',width: 90}, |
| | | {field: 'LotText',title: '批次描述',align: 'center', width: 100}, |
| | | {field: 'PackagName',title: '包装名称',align: 'center', width: 120}, |
| | | {field: 'SupplierLot',title: '供货批次',align: 'center', width: 120}, |
| | | {field: 'Price',title: '单价', align: 'center', width: 80}, |
| | | {field: 'Money',title: '总金额', align: 'center', width: 90}, |
| | | {field: 'caozuo',title: '操作',fixed: 'right',width: 100,align: 'left',toolbar: '#table-content-list2', "disabled": true} |
| | | ]]; |
| | | {field: '',title: '序号',type:'numbers',width: 50,align: 'center',fixed: 'left', "disabled": true}, |
| | | {field: 'SONo',title: '出库单号',align: 'center',fixed: 'left',width:165 }, |
| | | {field: 'SkuNo',title: '物料编码',align: 'center', width: 130}, |
| | | {field: 'SkuName',title: '物料名称',align: 'center', width: 152}, |
| | | {field: 'Standard',title: '物料规格',align: 'center', width: 270}, |
| | | {field: 'LotNo',title: '进厂编号',align: 'center',width: 150}, |
| | | {field: 'Qty',title: '计划数量',align: 'center',width: 100}, |
| | | {field: 'AllotQty',title: '分配数量',align: 'center',width: 100}, |
| | | {field: 'FactQty',title: '下架数量',align: 'center', width: 100}, |
| | | {field: 'CompleteQty',title: '拣货数量',align: 'center', width: 100}, |
| | | {field: 'IsBale',title: '是否裹包',align: 'center',templet: '#templetIsBale',width: 90}, |
| | | {field: 'IsBelt',title: '是否打带',align: 'center',templet: '#templetIsBelt',width: 90}, |
| | | {field: 'LotText',title: '批次描述',align: 'center', width: 100}, |
| | | {field: 'PackagName',title: '包装名称',align: 'center', width: 120}, |
| | | {field: 'SupplierLot',title: '原厂批号',align: 'center', width: 120}, |
| | | {field: 'Price',title: '单价', align: 'center', width: 80}, |
| | | {field: 'Money',title: '总金额', align: 'center', width: 90}, |
| | | {field: 'caozuo',title: '操作',fixed: 'right',width: 100,align: 'left',toolbar: '#table-content-list2', "disabled": true} |
| | | ]]; |
| | | var DetailColsSysArr=encodeURIComponent(encodeURIComponent(JSON.stringify(DetailColsArr)))//将表头数据进行url编码 |
| | | //#endregion |
| | | function refreshTablemx(soNo) { |
| | | //#region 原始非自定义列 |
| | | // var param = { |
| | | // SoNo: soNo, |
| | | // }; |
| | | // table.render({ |
| | | // elem: '#LAY-app-content-list2', |
| | | // url: IP + "/BllSo/GetExportNoticeDetailList", |
| | | // method: 'POST', |
| | | // height: h2, |
| | | // id: 'LAY-app-content-list2', |
| | | // where: param, |
| | | // contentType: 'application/json', |
| | | // headers:{ToKen:$.cookie('token')}, |
| | | // toolbar:'#toolbarDemo', |
| | | // defaultToolbar: ['print'], //'print', 'exports' |
| | | // page: true, |
| | | // limit: pageCnt, |
| | | // limits: pageLimits, |
| | | // cellMinWidth: 60, //全局定义常规单元格的最小宽度,layui 2.2.1 新增 |
| | | // done: function(){ |
| | | // initMenu(); |
| | | // }, |
| | | // cols: [ |
| | | // [{ |
| | | // title: '序号', |
| | | // type: 'numbers', |
| | | // width: 65, |
| | | // fixed: 'left', |
| | | // }, { |
| | | // field: 'SONo', |
| | | // title: '出库单号', |
| | | // align: 'center', |
| | | // fixed: 'left', |
| | | // width: 165 |
| | | // }, { |
| | | // field: 'SkuNo', |
| | | // title: '物料编码', |
| | | // align: 'center', |
| | | // width: 130 |
| | | // }, { |
| | | // field: 'SkuName', |
| | | // title: '物料名称', |
| | | // align: 'center', |
| | | // width: 152 |
| | | // }, { |
| | | // field: 'Standard', |
| | | // title: '物料规格', |
| | | // align: 'center', |
| | | // width: 270 |
| | | // }, { |
| | | // field: 'LotNo', |
| | | // title: '批次号', |
| | | // align: 'center', |
| | | // width: 150 |
| | | // }, { |
| | | // field: 'Qty', |
| | | // title: '计划数量', |
| | | // align: 'center', |
| | | // width: 100 |
| | | // }, { |
| | | // field: 'AllotQty', |
| | | // title: '分配数量', |
| | | // align: 'center', |
| | | // width: 100 |
| | | // }, { |
| | | // field: 'FactQty', |
| | | // title: '下架数量', |
| | | // align: 'center', |
| | | // width: 100 |
| | | // }, { |
| | | // field: 'CompleteQty', |
| | | // title: '拣货数量', |
| | | // align: 'center', |
| | | // width: 100 |
| | | // }, { |
| | | // field: 'IsBale', |
| | | // title: '是否裹包', |
| | | // align: 'center', |
| | | // templet: function (d) { |
| | | // console.log(d); |
| | | // switch (d.IsBale) { |
| | | // case "0": |
| | | // return "不裹包"; |
| | | // case "1": |
| | | // return "裹包"; |
| | | // default: |
| | | // return ""; |
| | | // } |
| | | |
| | | // }, |
| | | // width: 90, |
| | | // hide:true, |
| | | // }, { |
| | | // field: 'IsBelt', |
| | | // title: '是否打带', |
| | | // align: 'center', |
| | | // templet: function (d) { |
| | | // switch (d.IsBelt) { |
| | | // case "0": |
| | | // return "不打带"; |
| | | // case "1": |
| | | // return "打带"; |
| | | // default: |
| | | // return ""; |
| | | // } |
| | | |
| | | // }, |
| | | // width: 90, |
| | | // hide:true, |
| | | // }, { |
| | | // field: 'LotText', |
| | | // title: '批次描述', |
| | | // align: 'center', |
| | | // width: 100 |
| | | // }, { |
| | | // field: 'PackagName', |
| | | // title: '包装名称', |
| | | // align: 'center', |
| | | // width: 120 |
| | | // }, { |
| | | // field: 'SupplierLot', |
| | | // title: '供货批次', |
| | | // align: 'center', |
| | | // width: 120 |
| | | // }, |
| | | // // { |
| | | // // field: 'IsWave', |
| | | // // title: '生成波次', |
| | | // // align: 'center', |
| | | // // width: 90, |
| | | // // templet: function (d) { |
| | | // // switch (d.IsWave) { |
| | | // // case "0": |
| | | // // return "否"; |
| | | // // case "1": |
| | | // // return "是"; |
| | | // // default: |
| | | // // return ""; |
| | | // // } |
| | | |
| | | // // }, |
| | | // // hide:true, |
| | | // // }, |
| | | // // { |
| | | // // field: 'WaveNo', |
| | | // // title: '波次单号', |
| | | // // align: 'center', |
| | | // // width: 170, |
| | | // // hide:true |
| | | // // }, |
| | | // { |
| | | // field: 'Price', |
| | | // title: '单价', |
| | | // align: 'center', |
| | | // width: 80, |
| | | // hide:true |
| | | // }, { |
| | | // field: 'Money', |
| | | // title: '总金额', |
| | | // align: 'center', |
| | | // width: 90, |
| | | // hide:true |
| | | // }, { |
| | | // title: '操作', |
| | | // fixed: 'right', |
| | | // width: 180, |
| | | // align: 'center', |
| | | // toolbar: '#table-content-list2' |
| | | // }] |
| | | // ] |
| | | // }); |
| | | //#endregion |
| | | |
| | | |
| | | //#region 自定义表头 |
| | | var colsJson2 |
| | | var param1={ |
| | |
| | | isChongFu= false; |
| | | if(pa == null) |
| | | { |
| | | layer.msg("请选择出库口", { |
| | | layer.msg("请勿重复点击", { |
| | | icon: 2, |
| | | time: 2000 //2秒关闭(如果不配置,默认是3秒) |
| | | }); |
| | | isChongFu= true; |
| | | return; |
| | | } |
| | | if($('#UnstackWay').val()=='0'){ |
| | |
| | | }); |
| | | isChongFu= true; |
| | | return; |
| | | } |
| | | isChongFu= true; |
| | | return; |
| | | } |
| | | if(isNeedUnpack=='1'){ |
| | | if(pa==''){ |
| | | layer.msg("请选择出库口", { |
| | | icon: 2, |
| | | time: 2000 //2秒关闭(如果不配置,默认是3秒) |
| | | }); |
| | | isChongFu= true; |
| | | return; |
| | | } |
| | | } |
| | | }else{ |
| | | if(pa==''){ |
| | | layer.msg("请选择出库口", { |
| | | icon: 2, |
| | | time: 2000 //2秒关闭(如果不配置,默认是3秒) |
| | | }); |
| | | isChongFu= true; |
| | | return; |
| | | } |
| | | } |
| | | var param = { |
| | | soNo: soNo, |