| | |
| | | var type = params[params[2]]; |
| | | //原生成条码方法(送货单默认) |
| | | var mainUrl = "GetHBarCodeShowBillMain"; //表头数据加载ajax |
| | | var subUrl = "GetHBarCodeShowBillSub";//表体数据加载ajax |
| | | var subUrl = "GetHBarCodeShowBillSub";//表体数据加载ajax h_v_SRM_POInStockBillSub_ForWeb2 |
| | | var saveBarCode = "GetBarcodeSaveBillBox";//条码生成保存方法ajax |
| | | var openTmpListType = "SRM_POInStockBillList"; //条码打印按钮 弹出界面 |
| | | //采购订单条码生成规则 |
| | | if (type == 'SRM_POOrderBillList') { |
| | | mainUrl = 'GetHBarCodeShowBillMainBycg'; |
| | | subUrl = "GetHBarCodeShowBillSubBycg"; |
| | | subUrl = "GetHBarCodeShowBillSubBycg"; //h_v_Cg_POOrderBillSub_ForWeb2 |
| | | saveBarCode = "GetBarcodeSaveBillBoxBycg"; |
| | | openTmpListType = 'SRM_POOrderBillList'; |
| | | |
| | |
| | | //委外订单 |
| | | else if (type == 'SRM_EntrustOrderBill') { |
| | | mainUrl = 'GetHBarCodeShowBillMainBywy'; |
| | | subUrl = "GetHBarCodeShowBillSubBywy"; |
| | | subUrl = "GetHBarCodeShowBillSubBywy"; //h_v_srm_EntrustOrderBillSub_ForWeb2 |
| | | saveBarCode = "GetBarcodeSaveBillBoxBycg";//调用采购数据 |
| | | openTmpListType = 'SRM_POOrderBillList'; |
| | | } |
| | |
| | | }); |
| | | table.render({ |
| | | elem: '#subTable' |
| | | , url: GetWEBURL() + 'GetHBarCodeShowBillSub3' |
| | | , url: GetWEBURL() + 'GetHBarCodeShowBillSub3' //h_v_Web_BarCodeBill_ForWeb1 |
| | | , toolbar: '#toolbarDemo1' |
| | | , defaultToolbar: ['filter', 'exports'] |
| | | , where: { sMsg: linterid } |
| | |
| | | , where: { sMsg: linterid, sMsg2: lentryid } |
| | | , cols: [[ |
| | | , { field: 'HMaterID', title: '物料ID', width: 100, hide: true } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 100 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 200 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 200 } |
| | | , { field: 'HMaterShortNumber', title: '物料编码', width: 120 } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 120 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 120 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 120 } |
| | | , { field: 'HUnitName', title: '计量单位', width: 100 } |
| | | , { field: 'HUnitNumber', title: '计量单位代码', width: 100, hide: true } |
| | | , { field: 'HUnitID', title: '计量单位ID', width: 100, hide: true } |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料编码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HShortNumber" id="HShortNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料代码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HNumber" id="HNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">产品名称</label> |
| | | <label class="layui-form-label">物料名称</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HName" id="HName"> |
| | | </div> |
| | |
| | | sqlWhere += " and 条码编号 like ^^%" + $("#HBarCode").val() + "%^^"; |
| | | if ($("#HSourceBillNo").val() != "") |
| | | sqlWhere += " and 源单单号 like ^^%" + $("#HSourceBillNo").val() + "%^^"; |
| | | if ($("#HShortNumber").val() != "") |
| | | sqlWhere += " and 物料编码 like ^^%" + $("#HShortNumber").val() + "%^^"; |
| | | if ($("#HNumber").val() != "") |
| | | sqlWhere += " and 物料代码 like ^^%" + $("#HNumber").val() + "%^^"; |
| | | if ($("#HName").val() != "") |
| | |
| | | RoadBillMain(linterid); |
| | | RoadBillSub(linterid); |
| | | // debugger; |
| | | function RoadBillMain(linterid) |
| | | { |
| | | function RoadBillMain(linterid) { |
| | | $.ajax({ |
| | | url: GetWEBURL()+"GetEntrustOrderShowBillMain", |
| | | url: GetWEBURL() + "GetEntrustOrderShowBillMain", //H_v_SRM_EntrustOrderBillMain_ForWeb |
| | | type: "GET", |
| | | data: { "sMsg": linterid }, |
| | | success: function (d) { |
| | |
| | | function RoadBillSub(linterid) { |
| | | $.ajax({ |
| | | type: "get", |
| | | url: GetWEBURL()+"GetEntrustOrderShowBillSub", |
| | | url: GetWEBURL() + "GetEntrustOrderShowBillSub",//[h_v_srm_EntrustOrderBillSub_ForWeb2] |
| | | async: true, |
| | | data: { sMsg: linterid }, |
| | | success: function (result) { |
| | |
| | | ,cols: [[ |
| | | , { field: 'HMTONO', title: '计划跟踪单号', width: 100, sort: true, fixed: true , hide: true } |
| | | , { field: 'HMaterID', title: '物料ID', width: 100, hide: true } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 200 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 200 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 200 } |
| | | , { field: 'HMaterShortNumber', title: '物料编码', width: 120 } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 120 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 120 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 120 } |
| | | , { field: 'HUnitName', title: '计量单位', width: 100 } |
| | | , { field: 'HUnitNumber', title: '计量单位代码', width: 100, hide: true } |
| | | , { field: 'HUnitID', title: '计量单位ID', width: 100, hide: true } |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料编码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HShortNumber" id="HShortNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料代码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HNumber" id="HNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">产品名称</label> |
| | | <label class="layui-form-label">物料名称</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HName" id="HName"> |
| | | </div> |
| | |
| | | sqlWhere += " and 状态 like ^^%" + $("#HStatus").val() + "%^^"; |
| | | if ($("#HBillNo").val() != "") |
| | | sqlWhere += " and 单据号 like ^^%" + $("#HBillNo").val() + "%^^"; |
| | | if ($("#HShortNumber").val() != "") |
| | | sqlWhere += " and 物料编码 like ^^%" + $("#HShortNumber").val() + "%^^"; |
| | | if ($("#HNumber").val() != "") |
| | | sqlWhere += " and 物料代码 like ^^%" + $("#HNumber").val() + "%^^"; |
| | | if ($("#HName").val() != "") |
| | |
| | | , cols: [[ |
| | | // , { field: 'HMTONO', title: '计划跟踪单号', width: 100,, sort: true, fixed: true edit: 'text', hide: true } |
| | | , { field: 'HMaterID', title: '物料ID', width: 100, edit: 'text', hide: true } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 100 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 200 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 200 } |
| | | , { field: 'HMaterShortNumber', title: '物料编码', width: 120 } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 120 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 120 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 120 } |
| | | , { field: 'HUnitName', title: '计量单位', width: 100 } |
| | | , { field: 'HUnitNumber', title: '计量单位代码', width: 100, hide: true } |
| | | , { field: 'HUnitID', title: '计量单位ID', width: 100, hide: true } |
| | | , { field: 'HQty', title: '数量', width: 100 } |
| | | , { field: 'HPrice', title: '单价', width: 100 } |
| | | , { field: 'HMoney', title: '金额', width: 100 } |
| | | , { field: 'HPrice', title: '单价', width: 100, hide: true} |
| | | , { field: 'HMoney', title: '金额', width: 100, hide: true} |
| | | , { field: 'HWHName', title: '收料仓库', width: 100 } |
| | | , { field: 'HWHNumber', title: '收料仓库代码', width: 100, hide: true } |
| | | , { field: 'HWHID', title: '收料仓库ID', width: 100, hide: true } |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料编码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HShortNumber" id="HShortNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料代码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HNumber" id="HNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">产品名称</label> |
| | | <label class="layui-form-label">物料名称</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HName" id="HName"> |
| | | </div> |
| | |
| | | sqlWhere += " and 单据号 like ^^%" + $("#HBillNo").val() + "%^^"; |
| | | if ($("#HInnerBillNo").val() != "") |
| | | sqlWhere += " and 送货单号 like ^^%" + $("#HInnerBillNo").val() + "%^^"; |
| | | if ($("#HShortNumber").val() != "") |
| | | sqlWhere += " and 物料编码 like ^^%" + $("#HShortNumber").val() + "%^^"; |
| | | if ($("#HNumber").val() != "") |
| | | sqlWhere += " and 物料代码 like ^^%" + $("#HNumber").val() + "%^^"; |
| | | if ($("#HName").val() != "") |
| | |
| | | RoadBillMain(linterid); |
| | | RoadBillSub(linterid); |
| | | // debugger; |
| | | function RoadBillMain(linterid) |
| | | { |
| | | function RoadBillMain(linterid) { |
| | | $.ajax({ |
| | | url: GetWEBURL()+"GetPOOrderShowBillMain", |
| | | type: "GET", |
| | |
| | | layer.load(3) |
| | | table.render({ |
| | | elem: '#mainTable' |
| | | , url: GetWEBURL()+'GetPOOrderShowBillSub' |
| | | , url: GetWEBURL() + 'GetPOOrderShowBillSub' //H_v_SRM_POOrderBillSub_ForWeb |
| | | , toolbar: '#toolbarDemo' //开启头部工具栏,并为其绑定左侧模板 |
| | | , defaultToolbar: ['filter', 'exports'] |
| | | , where: { sMsg: linterid } |
| | | ,cols: [[ |
| | | , { field: 'HMTONO', title: '计划跟踪单号', width: 100, sort: true, fixed: true , hide: true } |
| | | , { field: 'HMaterID', title: '物料ID', width: 100, hide: true } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 200 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 200 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 200 } |
| | | , { field: 'HMaterShortNumber', title: '物料编码', width: 120 } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 120 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 120 } |
| | | , { field: 'HMaterModel', title: '规格型号', width: 120 } |
| | | , { field: 'HUnitName', title: '计量单位', width: 100 } |
| | | , { field: 'HUnitNumber', title: '计量单位代码', width: 100, hide: true } |
| | | , { field: 'HUnitID', title: '计量单位ID', width: 100, hide: true } |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料编码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HShortNumber" id="HShortNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">物料代码</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HNumber" id="HNumber"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <label class="layui-form-label">产品名称</label> |
| | | <label class="layui-form-label">物料名称</label> |
| | | <div class="layui-input-block"> |
| | | <input type="text" class="layui-input" name="HName" id="HName"> |
| | | </div> |
| | |
| | | sqlWhere += " and 状态 like ^^%" + $("#HStatus").val() + "%^^"; |
| | | if ($("#HBillNo").val() != "") |
| | | sqlWhere += " and 单据号 like ^^%" + $("#HBillNo").val() + "%^^"; |
| | | if ($("#HShortNumber").val() != "") |
| | | sqlWhere += " and 物料编码 like ^^%" + $("#HShortNumber").val() + "%^^"; |
| | | if ($("#HNumber").val() != "") |
| | | sqlWhere += " and 物料代码 like ^^%" + $("#HNumber").val() + "%^^"; |
| | | if ($("#HName").val() != "") |