| | |
| | | <div class="layui-btn-group"> |
| | | |
| | | <button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Saver">保存</button> |
| | | <button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Aduit">审核</button> |
| | | <button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Print">打印</button> |
| | | <button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Exit">退出</button> |
| | | |
| | | </div> |
| | |
| | | <div class="layui-col-xs3"> |
| | | <label class="layui-form-label"> 送货单号:</label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="HInnerBillNo" id="HInnerBillNo" readonly autocomplete="off"> |
| | | <input class="layui-input" name="HInnerBillNo" id="HInnerBillNo" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-col-xs3"> |
| | | <!--<div class="layui-col-xs3"> |
| | | <label class="layui-form-label"> 物流单号:</label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="HDeliveryNo" id="HDeliveryNo" autocomplete="off"> |
| | | <input class="layui-input" name="HDeliveryNo" id="HDeliveryNo" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-col-xs6"> |
| | |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="HRemark" id="HRemark" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | </div>--> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | { type: 'checkbox', fixed: 'left' } |
| | | , { field: 'sorderid', title: '序号', width: 80, hide: true, fixed: true } |
| | | , { field: 'HMTONO', title: '计划跟踪单号', width: 100, fixed: true, edit: 'text', hide: true } |
| | | , { field: 'F_xbkf_Combo', title: '自定义标识', width: 120 } |
| | | , { field: 'FSHDD', title: '送货地点', width: 120 } |
| | | , { field: 'HMaterID', title: '物料ID', width: 100, hide: true } |
| | | , { field: 'HMaterNumber', title: '物料代码', width: 100 } |
| | | , { field: 'HMaterName', title: '物料名称', width: 200 } |
| | |
| | | , { 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, edit: 'text', event: "inputHQty" } |
| | | , { field: 'HQty', title: '送货数量', width: 100, edit: 'text'/*, event: "inputHQty"*/ } |
| | | , { field: 'HRQty', title: '未入库数量', width: 100 } |
| | | , { field: 'HSQty', title: '源单数量', width: 100 } |
| | | , { field: 'HBatchNo', title: '批次', width: 100, edit: 'text' } |
| | | , { field: 'HBatchNo', title: '批次', width: 100, edit: 'text' } |
| | | , { field: 'HKFDate', title: '生产日期', align: 'center', width: 150, data_field: 'HKFDate', event: "chooseHKFDate" } |
| | | , { field: 'HKFPeriod', title: '保质期', width: 100 } |
| | | , { field: 'HDate', title: '预计到货日期', align: 'center', width: 150, data_field: 'HDate', event: "chooseHDate", hide: true } |
| | | , { 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: 'HRemark', title: '备注', width: 100 } |
| | | , { field: 'HPOOrderInterID', title: '采购订单主内码', width: 150, hide: true } |
| | | , { field: 'HPOOrderEntryID', title: '采购订单子内码', width: 150, hide: true } |
| | |
| | | } |
| | | }); |
| | | }); |
| | | form.on('submit(Aduit)', function (data) {//审核 |
| | | $.ajax( |
| | | { |
| | | type: "GET", |
| | | url: GetWEBURL() + "/AuditPOInStockBill", //方法所在页面和方法名 |
| | | async: true, |
| | | data: { "HInterID": "", "CurUserName": sessionStorage["HUserName"], "HBillNo": $("#HBillNo").val() }, |
| | | dataType: "json", |
| | | success: function (data) { |
| | | if (data.count == 1) { // 说明验证成功了, |
| | | layer.msg(data.Message, { icon: 1 }); |
| | | } |
| | | else { |
| | | f_alert(data.Message); |
| | | } |
| | | layer.closeAll("loading"); |
| | | }, |
| | | error: function (err) { |
| | | f_alert("错误:" + err); |
| | | } |
| | | }); |
| | | }); |
| | | form.on('submit(Print)', function (data) {//审核 |
| | | $.ajax( |
| | | { |
| | | type: "GET", |
| | | url: GetWEBURL() + "/GetHinterID", //方法所在页面和方法名 |
| | | async: true, |
| | | data: { "HBillNo": $("#HBillNo").val() }, |
| | | dataType: "json", |
| | | success: function (data) { |
| | | if (data.count == 1) { // 说明验证成功了, |
| | | layer.open({ |
| | | type: 2 |
| | | , area: ['50%', '50%'] |
| | | , title: '打印模版选择' |
| | | , shade: 0.6 //遮罩透明度 |
| | | , maxmin: false //允许全屏最小化 |
| | | , anim: 0 //0-6的动画形式,-1不开启 |
| | | , content: ['../../views/BaseSet/SRM_OpenTmpList.html?linterid=' + data.data.toString() + '&MyMsg=' + data.data.toString() + '&Type=SRM_POInStockBillList', 'yes'] |
| | | , resize: false |
| | | //, cancel: function () { |
| | | // $(".layui-btn").removeClass("layui-btn-disabled"); |
| | | //} |
| | | }) |
| | | } |
| | | else { |
| | | f_alert(data.Message); |
| | | } |
| | | layer.closeAll("loading"); |
| | | }, |
| | | error: function (err) { |
| | | f_alert("错误:" + err); |
| | | } |
| | | }); |
| | | }); |
| | | form.on('submit(Exit)', function (data) {//保存 |
| | | var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引 |
| | | parent.layer.close(index); //再执行关闭 |
| | |
| | | //非空验证 |
| | | function AllowLoadData(sSubStr) { |
| | | var Result = true; |
| | | if ($("#HDHDate").val() == '' || $("#HDHDate").val() == null) { |
| | | layer.msg("预计到货日期不能为空!", { icon: 5, btn: ['确认'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "温馨提示" }); |
| | | return Result = false; |
| | | //if ($("#HDHDate").val() == '' || $("#HDHDate").val() == null) { |
| | | // layer.msg("预计到货日期不能为空!", { icon: 5, btn: ['确认'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "温馨提示" }); |
| | | // return Result = false; |
| | | //} |
| | | //if ($("#HDeliveryNo").val() == '' || $("#HDeliveryNo").val() == null) { |
| | | // layer.msg("物流单号不能为空!", { icon: 5, btn: ['确认'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "温馨提示" }); |
| | | // return Result = false; |
| | | //} |
| | | if (typeof (sSubStr) != "undefined" && typeof (sSubStr) != "") { |
| | | sSubStr = JSON.parse(sSubStr); |
| | | for (var i = 0; i < sSubStr.length; i++) { |
| | | if (sSubStr[i].HQty == "") { |
| | | layer.msg("明细记录第" + (i + 1) + "行,送货数量为空!", { icon: 5, btn: ['确认'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "温馨提示" }); |
| | | return Result = false; |
| | | } |
| | | } |
| | | } |
| | | if ($("#HDeliveryNo").val() == '' || $("#HDeliveryNo").val() == null) { |
| | | layer.msg("物流单号不能为空!", { icon: 5, btn: ['确认'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "温馨提示" }); |
| | | return Result = false; |
| | | else { |
| | | return Result = true; |
| | | } |
| | | return Result; |
| | | } |