You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1641 lines
78 KiB
1641 lines
78 KiB
@{
|
|
ViewBag.Title = "Index";
|
|
Layout = "~/Views/Shared/_Index.cshtml";
|
|
}
|
|
|
|
<script src="~/Content/js/datepicker/WdatePicker.js"></script>
|
|
<script>
|
|
debugger;
|
|
var _Clos = new Array();
|
|
var _Clos1 = new Array();
|
|
var flag = '1';
|
|
var mark = '拣料';
|
|
var Arguments = '';
|
|
|
|
//var PickID = '';
|
|
$(function () {
|
|
|
|
SetCols();
|
|
gridList();
|
|
/*gridList2(flag);*/
|
|
|
|
});
|
|
function Seach() {
|
|
var Type = $("#selShow").val();
|
|
document.getElementById("gridPanel").innerHTML = ' <span><strong>详细信息</strong></span> <table id="gridList"></table> ';//重置grid
|
|
document.getElementById("page").innerHTML = ' <table id="gridList"></table> <div id = "gridPager" ></div > ';
|
|
SetCols();
|
|
if (Type == 13 || Type == 14 || Type == 15 || Type == 16 || Type == 17) {
|
|
if (Type == 13) {
|
|
gridList7();
|
|
}
|
|
if (Type == 14) {
|
|
gridList9();
|
|
}
|
|
if (Type == 15) {
|
|
gridList5();
|
|
}
|
|
if (Type == 16) {
|
|
gridList12();
|
|
}
|
|
if (Type == 17) {
|
|
gridList4();
|
|
}
|
|
}
|
|
else {
|
|
gridList();
|
|
}
|
|
|
|
|
|
}
|
|
|
|
$(function () {
|
|
SetCols();
|
|
var Type = $("#selShow").val();
|
|
if (Type == 13 || Type == 14 || Type == 15 || Type == 16 || Type == 17) {
|
|
//$(".outWarehouse").css('display', 'none');
|
|
//if (Type == '17' || Type == '15' || Type == '14') {
|
|
// $(".HideItems").css('display', 'none');
|
|
//}
|
|
//if (Type != '14') {
|
|
// $(".Workorder").css('display', 'none');
|
|
//}
|
|
//if (Type != '13') {
|
|
// $(".txt_DNID1").css('display', 'none');
|
|
//}
|
|
|
|
|
|
if (Type == '17') {
|
|
gridList4();
|
|
}
|
|
if (Type == '15') {
|
|
gridList5();
|
|
}
|
|
|
|
//审核到货单生成条码
|
|
if (Type == '13') {
|
|
gridList7();
|
|
}
|
|
//审核委外到货单生成条码
|
|
|
|
//开立成品入库单生成条码
|
|
if (Type == '14') {
|
|
$(".HideItems9").css('display', 'none');
|
|
gridList9();
|
|
}
|
|
|
|
|
|
//领料申请退料生成条码
|
|
if (Type == '16') {
|
|
gridList12();
|
|
}
|
|
}
|
|
else {
|
|
/* $(".insWarehouse").css('display', 'none'); */
|
|
gridList();
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
function SetCols() {
|
|
var Type = $("#selShow").val();
|
|
var cols = new Array();
|
|
var cols1 = new Array();
|
|
if (Type == 13 || Type == 14 || Type == 15 || Type == 16 || Type == 17) {
|
|
if (Type == '17') {
|
|
var collast = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols.push(collast);
|
|
var collast = { label: '单据号', name: 'SDNCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '行号', name: 'Sequence', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售订单号', name: 'SOCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售订单行号', name: 'SOSequence', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '区域', name: 'Area', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '仓库', name: 'WHCode', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '客户代码', name: 'CusCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '客户名称', name: 'CusName', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '发货日期', name: 'ArriveDate', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '已发数量', name: 'SDNQuantity', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品编码', name: 'InvCode', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述', name: 'InvDescribe', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '数量', name: 'Quantity', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = {
|
|
label: "状态", name: "Status", width: 60, align: "left",
|
|
formatter: function (cellvalue) {
|
|
if (cellvalue == "1") {
|
|
return "开立";
|
|
} else if (cellvalue == "2") {
|
|
return "审核";
|
|
}
|
|
else if (cellvalue == "3") {
|
|
return "关闭";
|
|
}
|
|
else { return ""; }
|
|
}
|
|
};
|
|
cols.push(collast);
|
|
var collast = { label: '规格型号', name: 'InvStd', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '单位', name: 'InvUnit', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '已生成数量', name: 'LOTQTY', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
|
|
|
|
var collast = { label: '站点', name: 'WorkPoint', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '装运点', name: 'Points', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '交货类型', name: 'DeliveryType', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '交货描述', name: 'DeliveryDescribe', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅助描述', name: 'OtherDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售单位', name: 'SalesUnit', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '序列号参数', name: 'IsSerialNumber', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
}
|
|
if (Type == '15') {
|
|
var collast = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols.push(collast);
|
|
var collast = { label: '单据号', name: 'InCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '行号', name: 'Sequence', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '区域', name: 'Area', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '仓库', name: 'WHCode', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品编码', name: 'InvCode', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅助描述', name: 'InvDesc', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品型号', name: 'InvStd', width: 150, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
var collast = { label: '料品单位', name: 'InvStd', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '数量', name: 'Quantity', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '已生成数量', name: 'LOTQTY', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '已入数量', name: 'InQuantity', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '创建人', name: 'CreatePerson', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '创建时间', name: 'CreateDateTime', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
|
|
//cols.push(collast);
|
|
|
|
var collast = { label: '站点', name: 'WorkPoint', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '单据类型', name: 'OrderType', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '类型描述', name: 'TypeDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '成本中心', name: 'CostCenter', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '备注', name: 'Remarks', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '人员号', name: 'PersonNumber', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述', name: 'InvDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '基本计量单位', name: 'Unit', width: 150, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
}
|
|
//审核到货单生成条码
|
|
if (Type == '13') {
|
|
var collast = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols.push(collast);
|
|
var collast = { label: '单据号', name: 'DNCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '行号', name: 'Sequence', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '采购订单号', name: 'DNID', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '采购订单行号', name: 'DNDetailID', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品编码', name: 'InvCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述', name: 'InvoDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '区域', name: 'Area', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '仓库', name: 'WHCode', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '检验修改日期', name: 'ModificationDate', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '采购订单号', name: 'POCode', width: 50, align: 'left' };
|
|
//cols.push(collast);
|
|
//var collast = { label: '采购订单行号', name: 'POSequence', width: 50, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '供应商代码', name: 'VenCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '供应商名称', name: 'VenName', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
//新增字段
|
|
|
|
var collast = { label: '站点', name: 'WorkPoint', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '检验类型', name: 'InspectionType', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '不合格单号', name: 'NonconformingForm', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '图号', name: 'DrawingNo', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '图标', name: 'Version1', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '修改时间', name: 'ModificationDate', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '物料描述', name: 'InvoDescribe', width: 120, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 50, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
//var collast = { label: '单位', name: 'Unity', width: 50, align: 'left' };
|
|
//cols.push(collast);
|
|
|
|
|
|
|
|
var collast = { label: '辅助描述', name: 'InvDesc', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品型号', name: 'InvStd', width: 150, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
var collast = { label: '料品单位', name: 'InvUnit', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '数量', name: 'Quantity', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '已生成数量', name: 'LOTQTY', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '入库数量', name: 'RCVQuantity', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
//var collast = { label: '币种', name: 'Currency', width: 60, align: 'left', };
|
|
//cols.push(collast);
|
|
var collast = { label: '创建人', name: 'CreatePerson', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '创建时间', name: 'CreateDateTime', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '区域类型', name: 'AreaType', width: 10, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
}
|
|
//开立成品入库单生成条码
|
|
if (Type == '14') {
|
|
var collast = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols.push(collast);
|
|
var collast = { label: '单据号', name: 'RCVCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '行号', name: 'Sequence', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '仓库号', name: 'WHCode', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '生产订单', name: 'OrderNumber', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '存储区域', name: 'Area', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品编码', name: 'InvCode', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述', name: 'InvName', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅助描述', name: 'InvDesc', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品型号', name: 'InvStd', width: 150, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
var collast = { label: '料品单位', name: 'InvUnit', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '数量', name: 'Quantity', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '已生成数量', name: 'LOTQTY', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '入库数量', name: 'RCVQuantity', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '创建人', name: 'CreatePerson', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '创建时间', name: 'CreateDateTime', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
var collast = { label: '站点', name: 'WorkPoint', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '单据类型', name: 'EATTRIBUTE', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述', name: 'InvDescribe', width: 150, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
var collast = { label: '物料号(父项生产订单主物料)', name: 'OrderNumber', width: 200, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述(父项生产订单主物料)', name: 'OrderInvDescribe', width: 200, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '出入库', name: 'BillType', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '备注', name: 'Remarks', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '基本计量单位', name: 'Unit', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '备注项', name: 'RemarksTerm', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '区域类型', name: 'AreaType', width: 10, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
}
|
|
//领料申请退料生成条码
|
|
if (Type == '16') {
|
|
var collast = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols.push(collast);
|
|
var collast = { label: '退料单号', name: 'ApplyNegCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '退料单行号', name: 'Sequence', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: 'ERP子ID', name: 'SourceDetailID', hidden: true, };
|
|
cols.push(collast);
|
|
var collast = { label: '区域', name: 'Area', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '仓库', name: 'WHCode', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品编码', name: 'InvCode', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '料品编码', name: 'InvName', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '数量', name: 'Quantity', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '已退数量', name: 'IssueNegQuantity', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '规格型号', name: 'InvStd', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '单位', name: 'InvUnit', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
//var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '已生成数量', name: 'LOTQTY', width: 60, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '创建日期', name: 'CreateDateTime', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '区域类型', name: 'AreaType', width: 10, align: 'left', hidden: true };
|
|
cols.push(collast);
|
|
}
|
|
|
|
}
|
|
else {
|
|
|
|
var cols = new Array();
|
|
var collast = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols.push(collast);
|
|
var collast = { label: '单据号', name: 'Code', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '操作日期', name: 'MTIME', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
if (Type == 2 || Type == 12) {
|
|
|
|
|
|
var collast = { label: '物料号(父项生产订单物料)', name: 'OrderInvCode', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述(父项生产订单主物料)', name: 'OrderInvDescribe', width: 200, align: 'left' };
|
|
cols.push(collast);
|
|
//var collast = { label: '调度工号', name: 'DispatchNumber', width: 120, align: 'left', };
|
|
//cols.push(collast);
|
|
var collast = { label: '拣料人姓名', name: 'PickName', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '收料人姓名', name: 'ReceiverName', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '需求日期', name: 'NeedDate', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '需求时间', name: 'NeedTime', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
//var collast = { label: '收料人工号', name: 'ReceiverNumber', width: 150, align: 'left' };
|
|
//cols.push(collast);
|
|
|
|
var collast = { label: '紧急程度', name: 'Urgency', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '调度人姓名', name: 'DispatcherName', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '工位', name: 'Desks', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '状态', name: 'Status', width: 150, align: 'center' };
|
|
cols.push(collast);
|
|
|
|
}
|
|
else {
|
|
|
|
}
|
|
|
|
|
|
//var collast = { label: '维护人', name: 'MUSER', width: 80, align: 'left' };
|
|
//cols.push(collast);
|
|
//var collast = { label: '维护人名称', name: 'MUSERName', width: 80, align: 'left' };
|
|
//cols.push(collast);
|
|
//var collast = { label: '是否合并拣料', name: 'IsNew', width: 80, align: 'left' };
|
|
//cols.push(collast);
|
|
var collast = { label: '占料状态', name: 'IsOccupy', width: 80, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '单据状态', hidden: true, };
|
|
cols.push(collast);
|
|
|
|
var cols1 = new Array();
|
|
var collast1 = { label: "主键", name: "ID", hidden: true, key: true };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '领料合并ID', name: 'MergeID', width: 120, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '单据号', name: 'Code', width: 120, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '单据行号', name: 'Sequence', hidden: true };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '料品编码', name: 'InvCode', width: 150, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '物料描述', name: 'InvName', width: 150, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '规格型号', name: 'InvStd', width: 100, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '应发数量', name: 'iQuantity', width: 100, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '单位', name: 'InvUnit', width: 150, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '仓库编码', name: 'WarehouseCode', width: 100, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '库位编码', name: 'LocationCode', width: 100, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '条码库存', name: 'QTY', width: 100, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '条码', name: 'LotNO', width: 100, align: 'left' };
|
|
cols1.push(collast1);
|
|
var collast1 = { label: '占料数量', name: 'SendQTY', hidden: true };
|
|
cols1.push(collast1);
|
|
|
|
if (Type != 7) {
|
|
var collast = { label: '销售凭证', name: 'ProjectCode', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售凭证项号', name: 'Brand', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
|
|
}
|
|
else {
|
|
|
|
var collast = { label: '客户编码', name: 'CusCode', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '客户名称', name: 'CusName', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$.ajax({
|
|
url: "/Print/SelectColumnName?" + Math.random(),
|
|
dataType: "json",
|
|
async: false,
|
|
success: function (data) {
|
|
|
|
if (data != null && data.length > 0) {
|
|
DateList = data;
|
|
for (var i = 0; i < data.length; i++) {
|
|
var ColName = data[i].ColName;
|
|
var ColCode = data[i].ColCode;
|
|
var obj = new Array();
|
|
obj = {
|
|
label: ColName,
|
|
name: ColCode,
|
|
width: 80,
|
|
align: "left"
|
|
}
|
|
if (ColCode != "BatchCode" && ColCode != "Brand" && ColCode != "ProjectCode") {
|
|
cols.push(obj);
|
|
cols1.push(obj);
|
|
}
|
|
|
|
}
|
|
}
|
|
_Clos = cols;
|
|
_Clos1 = cols1;
|
|
}
|
|
|
|
});
|
|
}
|
|
|
|
|
|
function gridList() {
|
|
var Type = $("#selShow").val();
|
|
var $gridList = $("#gridList");
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
InvCode: $("#txt_InvCode").val(),
|
|
Area: $("#txt_Area").val(),
|
|
WHCode: $("#txt_WHCode").val(),
|
|
CusCode: "",
|
|
CusName: "",
|
|
Status: "1",
|
|
Status1: "2",
|
|
Order: "",
|
|
Container: "",
|
|
CreateDate: "",
|
|
NeedDate: "",
|
|
InvName: "",
|
|
EATTRIBUTE1: ""
|
|
|
|
}
|
|
if (Type == 2) {
|
|
$gridList.dataGrid({
|
|
url: "/WMS/PickMaterial/GetGridJson?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson), Type: Type },
|
|
height: $(window).height() - 200,
|
|
//async: false,//取消异步请求
|
|
width: $(window).width() - 500,
|
|
colModel: _Clos,
|
|
shrinkToFit: false,//宽度自适应
|
|
autowidth: true,
|
|
gridComplete: function () {
|
|
|
|
var strIds = $("#gridList").jqGrid("getDataIDs");
|
|
|
|
for (var i = 0; i < strIds.length; i++) {
|
|
var strValue = $("#gridList").jqGrid("getCell", strIds[i], "IsOccupy");//得到单元格数据
|
|
if (strValue == "已占料") {
|
|
$("#" + strIds[i]).find("td").css("background-color", "#C7EDCC");
|
|
}
|
|
}
|
|
},
|
|
rowNum: 20,
|
|
autoScroll: true,
|
|
sortname: 'NeedDate',
|
|
sortorder: "asc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
pager: "#gridPager",
|
|
|
|
subGrid: true, // (1)开启子表格支持
|
|
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid(subgrid_id, rowid)
|
|
},
|
|
});
|
|
}
|
|
else {
|
|
$gridList.dataGrid({
|
|
url: "/WMS/PickMaterial/GetGridJson?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson), Type: Type },
|
|
height: $(window).height() - 200,
|
|
//async: false,//取消异步请求
|
|
width: $(window).width() - 500,
|
|
colModel: _Clos,
|
|
shrinkToFit: false,//宽度自适应
|
|
autowidth: true,
|
|
gridComplete: function () {
|
|
|
|
var strIds = $("#gridList").jqGrid("getDataIDs");
|
|
|
|
for (var i = 0; i < strIds.length; i++) {
|
|
var strValue = $("#gridList").jqGrid("getCell", strIds[i], "IsOccupy");//得到单元格数据
|
|
if (strValue == "已占料") {
|
|
$("#" + strIds[i]).find("td").css("background-color", "#C7EDCC");
|
|
}
|
|
}
|
|
},
|
|
rowNum: 20,
|
|
autoScroll: true,
|
|
sortname: 'Code',
|
|
sortorder: "desc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
pager: "#gridPager",
|
|
|
|
subGrid: true, // (1)开启子表格支持
|
|
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid(subgrid_id, rowid)
|
|
},
|
|
});
|
|
}
|
|
|
|
|
|
|
|
function bindSubGrid(subgrid_id, rowid) {
|
|
var Type = $("#selShow").val();
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
var subgrid_table_id;
|
|
subgrid_table_id = subgrid_id + "_t"; // (3)根据subgrid_id定义对应的子表格的table的id
|
|
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
InvCode: $("#txt_InvCode").val(),
|
|
Area: $("#txt_Area").val(),
|
|
WHCode: $("#txt_WHCode").val(),
|
|
CusCode: "",
|
|
CusName: "",
|
|
Order: "",
|
|
Container: "",
|
|
CreateDate: "",
|
|
NeedDate: "",
|
|
InvName: "",
|
|
EATTRIBUTE1: ""
|
|
|
|
}
|
|
|
|
var subgrid_pager_id;
|
|
subgrid_pager_id = subgrid_id + "_pgr" // (4)根据subgrid_id定义对应的子表格的pager的id
|
|
|
|
// (5)动态添加子报表的table和pager
|
|
$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "' class='scroll'></table><div id='" + subgrid_pager_id + "' class='scroll'></div>");
|
|
var Code = $("#gridList").jqGrid('getRowData', rowid).Code;
|
|
//var Sequence = $("#gridList").jqGrid('getRowData', rowid).Sequence;
|
|
// (6)创建jqGrid对象
|
|
var cols = [{ label: '单据号', name: 'Code', width: 120, align: 'left' },
|
|
{ label: '单据行号', name: 'Sequence', width: 120, align: 'left' },
|
|
{ label: '操作日期', name: 'MTIME', width: 120, align: 'left' },
|
|
{ label: '料品编码', name: 'InvCode', width: 120, align: 'left' },
|
|
{ label: '物料描述', name: 'InvName', width: 120, align: 'left' },
|
|
{ label: '辅助描述', name: 'InvDes', width: 120, align: 'left' },
|
|
{ label: '规格型号', name: 'InvStd', width: 120, align: 'left' },
|
|
{ label: '批次', name: 'BatchCode', width: 100, align: 'left' },
|
|
{ label: '区域', name: 'Area', width: 100, align: 'left' },
|
|
{ label: '仓库', name: 'WHCode', width: 100, align: 'left' },
|
|
{ label: '数量', name: 'Quantity', width: 100, align: 'left' },
|
|
{ label: '已发数量', name: 'IssueQuantity', width: 120, align: 'left' },
|
|
{ label: '单位', name: 'InvUnit', width: 100, align: 'left' },
|
|
{ label: '维护人', name: 'MUSER', width: 120, align: 'left' },
|
|
{ label: '维护人名称', name: 'MUSERName', width: 150, align: 'left' },
|
|
{ label: '仓库编码', name: 'WHCode', width: 120, align: 'left' },
|
|
{ label: '仓库名称', name: 'WarehouseName', width: 120, align: 'left' },
|
|
];
|
|
if (Type == '2' || Type == '12') {
|
|
var collast = { label: "生产订单", name: "OrderNumber", width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: "单据类型", name: "EATTRIBUTE", width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '套数', name: 'Sets', width: 50, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料号(父项生产订单物料)', name: 'OrderInvCode', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述(父项生产订单主物料)', name: 'OrderInvDescribe', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '出入库', name: 'BillType', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '备注', name: 'Remarks', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '工位', name: 'Desks', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '调度工号', name: 'DispatchNumber', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '调度姓名', name: 'DispatcherName', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '收料人工号', name: 'ReceiverNumber', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '收料人姓名', name: 'ReceiverName', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '紧急程度', name: 'Urgency', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '需求日期', name: 'NeedDate', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '需求时间', name: 'NeedTime', width: 120, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '备注项', name: 'RemarksTerm', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '工艺文本码', name: 'TextNumber', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '基本剂量单位', name: 'Unit', width: 150, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
}
|
|
if (Type == '5') {
|
|
var collast = { label: '采购订单', name: 'SourceCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '采购订单行号', name: 'SourceSequence', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '供应商编码', name: 'VenCode', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '供应商名称', name: 'VenName', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
}
|
|
if (Type == '7') {
|
|
var collast = { label: '站点', name: 'WorkPoint', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '装运点', name: 'Points', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '交货类型', name: 'DeliveryType', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '交货描述', name: 'DeliveryDescribe', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '辅助描述', name: 'OtherDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售单位', name: 'SalesUnit', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '序列号参数', name: 'IsSerialNumber', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售凭证', name: 'ProjectCode', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '销售凭证项号', name: 'Brand', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
|
|
}
|
|
if (Type == '8') {
|
|
var collast = { label: '单据类型', name: 'OrderType', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '类型描述', name: 'TypeDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '成本中心', name: 'CostCenter', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '备注', name: 'Remarks', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '人员号', name: 'PersonNumber', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '物料描述', name: 'InvDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '基本计量单位', name: 'Unit', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
}
|
|
if (Type == '10') {
|
|
var collast = { label: '目标仓库', name: 'ToWarehouseCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '目标工厂', name: 'ReceiveWork', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: "单据类型", name: "OrderType", width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '站点', name: 'WorkPoint', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '类型描述', name: 'TypeDescribe', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '备注', name: 'Remarks', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '人员号', name: 'PersonNumber', width: 100, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '基本计量单位', name: 'Unit', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '特殊库存标识', name: 'StockIndicator', width: 150, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '接收物料', name: 'ReceiveInvCode', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '接收物料描述', name: 'ReceiveInvDescribe', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '接受特殊库存标识', name: 'ReceiveStock', width: 150, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '接受销售订单', name: 'ReceiveSales', width: 150, align: 'left', };
|
|
cols.push(collast);
|
|
var collast = { label: '接受行号', name: 'ReceiveSequence', width: 120, align: 'left' };
|
|
cols.push(collast);
|
|
var collast = { label: '备注2', name: 'Remark2', width: 100, align: 'left', };
|
|
cols.push(collast);
|
|
|
|
}
|
|
|
|
$("#" + subgrid_table_id).dataGrid({
|
|
cellEdit: true,
|
|
url: "/WMS/PickMaterial/GetSubGridJson?Code=" + Code + "&Type=" + Type + "&" + Math.random(), // (7)子表格数据对应的url,注意传入的contact.id参数
|
|
colModel: cols,
|
|
postData: { queryJson: JSON.stringify(queryJson) },
|
|
//colModel: ColModelSub,
|
|
//shrinkToFit: true,//宽度自适应
|
|
//multiselect: true,
|
|
prmNames: { search: "search" },
|
|
viewrecords: true,
|
|
height: "100%",
|
|
rowNum: 20,
|
|
pager: subgrid_pager_id,
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
//销售退货
|
|
function gridList4() {
|
|
var $gridList = $("#gridList");
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
InvCode: $("#txt_InvCode").val(),
|
|
InvName: "",
|
|
BatchCode: "",
|
|
Area: $("#txt_Area").val(),
|
|
Location: $("#txt_WHCode").val(),
|
|
Container: "2",
|
|
|
|
}
|
|
$gridList.dataGrid({
|
|
url: "/WMS/WMSCreateItemLot/GetGridJsonXiaoShou" + "?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson) },
|
|
height: $(window).height() - 200,
|
|
width: $(window).width() - 300,
|
|
colModel: _Clos,
|
|
|
|
width: "100%",
|
|
autowidth: true,
|
|
//shrinkToFit: true,
|
|
gridComplete: function () {
|
|
},
|
|
pager: "#gridPager",
|
|
sortname: 'SDNCode',
|
|
sortorder: "desc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
beforeSelectRow: function (rowid, e) {
|
|
$("#gridList").jqGrid('resetSelection');
|
|
return (true);
|
|
},
|
|
subGrid: true, // (1)开启子表格支持
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid4(subgrid_id, rowid)
|
|
}
|
|
});
|
|
|
|
}
|
|
|
|
function bindSubGrid4(subgrid_id, rowid) {
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
var subgrid_table_id;
|
|
subgrid_table_id = subgrid_id + "_t"; // (3)根据subgrid_id定义对应的子表格的table的id
|
|
|
|
var subgrid_pager_id;
|
|
subgrid_pager_id = subgrid_id + "_pgr" // (4)根据subgrid_id定义对应的子表格的pager的id
|
|
|
|
// (5)动态添加子报表的table和pager
|
|
$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "' class='scroll'></table><div id='" + subgrid_pager_id + "' class='scroll'></div>");
|
|
var SDNCode = $("#gridList").jqGrid('getRowData', rowid).SDNCode;
|
|
var Sequence = $("#gridList").jqGrid('getRowData', rowid).Sequence;
|
|
// (6)创建jqGrid对象
|
|
$("#" + subgrid_table_id).dataGrid({
|
|
cellEdit: true,
|
|
url: "/WMS/WMSCreateItemLot/GetSubGridJson?ApplyNegCode=" + SDNCode + "&Sequence=" + Sequence + "&Type=" + "4" + "&" + Math.random(), // (7)子表格数据对应的url,注意传入的contact.id参数
|
|
colmodel: [
|
|
{ label: "主键", name: "id", hidden: true, key: true },
|
|
{ label: "来源单据号", name: "transcode", width: 200, align: 'left' },
|
|
{ label: '来源单据行', name: 'transsequence', width: 200, align: 'left' },
|
|
{ label: '条码', name: 'lotno', width: 200, align: 'left' },
|
|
{ label: '条码数量', name: 'quantity', width: 200, align: 'left' },
|
|
{ label: '操作人', name: 'musername', width: 200, align: 'left' },
|
|
{ label: '操作时间', name: 'mtime', width: 200, align: 'left' },
|
|
],
|
|
//colModel: _Clos1,
|
|
//colModel: ColModelSub,
|
|
shrinkToFit: true,//宽度自适应
|
|
multiselect: true,
|
|
prmNames: { search: "search" },
|
|
viewrecords: true,
|
|
height: "100%",
|
|
rowNum: 20,
|
|
pager: subgrid_pager_id,
|
|
|
|
});
|
|
}
|
|
|
|
//其它入库生成条码
|
|
function gridList5() {
|
|
var $gridList = $("#gridList");
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
InvCode: $("#txt_InvCode").val(),
|
|
InvName: "",
|
|
BatchCode: "",
|
|
Area: $("#txt_Area").val(),
|
|
Location: $("#txt_WHCode").val(),
|
|
Container: "2",
|
|
|
|
|
|
}
|
|
$gridList.dataGrid({
|
|
url: "/WMS/WMSCreateItemLot/GetGridJsonQiTa" + "?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson) },
|
|
height: $(window).height() - 200,
|
|
width: $(window).width() - 300,
|
|
colModel: _Clos,
|
|
|
|
width: "100%",
|
|
autowidth: true,
|
|
//shrinkToFit: true,
|
|
gridComplete: function () {
|
|
},
|
|
pager: "#gridPager",
|
|
sortname: 'InCode',
|
|
sortorder: "desc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
//单选
|
|
//beforeSelectRow: function (rowid, e) {
|
|
// $("#gridList").jqGrid('resetSelection');
|
|
// return (true);
|
|
//},
|
|
subGrid: true, // (1)开启子表格支持
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid5(subgrid_id, rowid)
|
|
}
|
|
});
|
|
|
|
//$("#warehouse a.btn-default").click(function () {
|
|
// $("#warehouse a.btn-default").removeClass("active");
|
|
// $(this).addClass("active");
|
|
// $('#btn_search').trigger("click");
|
|
//});
|
|
//$("#btn_search").click(function () {
|
|
// var warehouse = $("#warehouse a.active").attr('data-value');
|
|
// var queryJson = {
|
|
// POCode: $("#txt_POCode").val(),
|
|
// InvCode: $("#txt_InvCode").val(),
|
|
// InvName: $("#txt_InvName").val(),
|
|
// BatchCode: $("#txt_BatchCode").val(),
|
|
// Area: $("#txt_Area").val(),
|
|
// Location: $("#txt_Location").val(),
|
|
// Container: $("#txt_Container :checked").val(),
|
|
|
|
// }
|
|
// $gridList.jqGrid('setGridParam', {
|
|
// page: 1,
|
|
// postData: { queryJson: JSON.stringify(queryJson) },
|
|
// }).trigger('reloadGrid');
|
|
//});
|
|
|
|
}
|
|
|
|
function bindSubGrid5(subgrid_id, rowid) {
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
var subgrid_table_id;
|
|
subgrid_table_id = subgrid_id + "_t"; // (3)根据subgrid_id定义对应的子表格的table的id
|
|
|
|
var subgrid_pager_id;
|
|
subgrid_pager_id = subgrid_id + "_pgr" // (4)根据subgrid_id定义对应的子表格的pager的id
|
|
|
|
// (5)动态添加子报表的table和pager
|
|
$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "' class='scroll'></table><div id='" + subgrid_pager_id + "' class='scroll'></div>");
|
|
var InCode = $("#gridList").jqGrid('getRowData', rowid).InCode;
|
|
var Sequence = $("#gridList").jqGrid('getRowData', rowid).Sequence;
|
|
// (6)创建jqGrid对象
|
|
$("#" + subgrid_table_id).dataGrid({
|
|
cellEdit: true,
|
|
url: "/WMS/WMSCreateItemLot/GetSubGridJson?ApplyNegCode=" + InCode + "&Sequence=" + Sequence + "&Type=" + "5" + "&" + Math.random(), // (7)子表格数据对应的url,注意传入的contact.id参数
|
|
colModel: [
|
|
{ label: "主键", name: "ID", hidden: true, key: true },
|
|
{ label: "来源单据号", name: "TransCode", width: 200, align: 'left' },
|
|
{ label: '来源单据行', name: 'TransSequence', width: 200, align: 'left' },
|
|
{ label: '条码', name: 'LotNo', width: 200, align: 'left' },
|
|
{ label: '条码数量', name: 'Quantity', width: 200, align: 'left' },
|
|
{ label: '操作人', name: 'MUSERName', width: 200, align: 'left' },
|
|
{ label: '操作时间', name: 'MTIME', width: 200, align: 'left' },
|
|
],
|
|
//colModel: _Clos1,
|
|
//colModel: ColModelSub,
|
|
shrinkToFit: true,//宽度自适应
|
|
multiselect: true,
|
|
prmNames: { search: "search" },
|
|
viewrecords: true,
|
|
height: "100%",
|
|
rowNum: 20,
|
|
pager: subgrid_pager_id,
|
|
|
|
});
|
|
}
|
|
|
|
//*审核到货单生成条码
|
|
function gridList7() {
|
|
debugger;
|
|
var $gridList = $("#gridList");
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
VenCode: "",
|
|
VenName: "",
|
|
Area: $("#txt_Area").val(),
|
|
Location: "",
|
|
InvCode: $("#txt_InvCode").val(),
|
|
InvName: "",
|
|
BatchCode: "",
|
|
Container: "2",
|
|
DNID: ""
|
|
}
|
|
$gridList.dataGrid({
|
|
url: "/WMS/WMSCreateItemLot/GetGridJsonSHDH" + "?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson) },
|
|
height: $(window).height() - 200,
|
|
width: $(window).width() - 300,
|
|
colModel: _Clos,
|
|
//colModel: [
|
|
// { label: "主键", name: "ID", hidden: true, key: true },
|
|
// { label: '单据号', name: 'DNCode', width: 120, align: 'left' },
|
|
// { label: '行号', name: 'Sequence', width: 50, align: 'left' },
|
|
// { label: '采购订单号', name: 'POCode', width: 50, align: 'left' },
|
|
// { label: '采购订单行号', name: 'POSequence', width: 50, align: 'left' },
|
|
// { label: '供应商代码', name: 'VenCode', width: 120, align: 'left' },
|
|
// { label: '供应商名称', name: 'VenName', width: 120, align: 'left' },
|
|
// { label: '料品编码', name: 'InvCode', width: 50, align: 'left' },
|
|
// { label: '物料描述', name: 'InvName', width: 120, align: 'left' },
|
|
// { label: '辅助描述', name: 'InvDesc', width: 50, align: 'left' },
|
|
// { label: '料品型号', name: 'InvStd', width: 150, align: 'left' },
|
|
// { label: '料品单位', name: 'InvUnit', width: 50, align: 'left' },
|
|
// { label: '数量', name: 'Quantity', width: 100, align: 'left' },
|
|
// { label: '批次', name: 'BatchCode', width: 100, align: 'left' },
|
|
// { label: '已生成数量', name: 'LOTQTY', width: 100, align: 'left' },
|
|
// { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' },
|
|
// { label: '入库数量', name: 'RCVQuantity', width: 60, align: 'left', },
|
|
// { label: '币种', name: 'Currency', width: 60, align: 'left', },
|
|
// { label: '创建人', name: 'CreatePerson', width: 60, align: 'left', },
|
|
// { label: '创建时间', name: 'CreateDateTime', width: 100, align: 'left' },
|
|
//],
|
|
//colModel: ColModelMain,
|
|
width: "100%",
|
|
autowidth: true,
|
|
//shrinkToFit: true,
|
|
gridComplete: function () {
|
|
},
|
|
pager: "#gridPager",
|
|
sortname: 'ModificationDate',
|
|
sortorder: "asc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
beforeSelectRow: function (rowid, e) {
|
|
},
|
|
subGrid: true, // (1)开启子表格支持
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid7(subgrid_id, rowid)
|
|
}
|
|
});
|
|
|
|
//$("#warehouse a.btn-default").click(function () {
|
|
// $("#warehouse a.btn-default").removeClass("active");
|
|
// $(this).addClass("active");
|
|
// $('#btn_search').trigger("click");
|
|
//});
|
|
//$("#btn_search").click(function () {
|
|
|
|
// var warehouse = $("#warehouse a.active").attr('data-value');
|
|
// var queryJson = {
|
|
// POCode: $("#txt_POCode").val(),
|
|
// VenCode: $("#txt_VenCode").val(),
|
|
// VenName: $("#txt_VenName").val(),
|
|
// Area: $("#txt_Area").val(),
|
|
// Location: $("#txt_Location").val(),
|
|
// InvCode: $("#txt_InvCode").val(),
|
|
// InvName: $("#txt_InvName").val(),
|
|
// BatchCode: $("#txt_BatchCode").val(),
|
|
// Container: $("#txt_Container :checked").val(),
|
|
// DNID: $("#txt_DNID").val()
|
|
// }
|
|
// $gridList.jqGrid('setGridParam', {
|
|
// postData: { queryJson: JSON.stringify(queryJson) },
|
|
// page: 1,
|
|
// }).trigger('reloadGrid');
|
|
//});
|
|
|
|
}
|
|
function bindSubGrid7(subgrid_id, rowid) {
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
var subgrid_table_id;
|
|
subgrid_table_id = subgrid_id + "_t"; // (3)根据subgrid_id定义对应的子表格的table的id
|
|
|
|
var subgrid_pager_id;
|
|
subgrid_pager_id = subgrid_id + "_pgr" // (4)根据subgrid_id定义对应的子表格的pager的id
|
|
|
|
// (5)动态添加子报表的table和pager
|
|
$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "' class='scroll'></table><div id='" + subgrid_pager_id + "' class='scroll'></div>");
|
|
var DNCode = $("#gridList").jqGrid('getRowData', rowid).DNCode;
|
|
var Sequence = $("#gridList").jqGrid('getRowData', rowid).Sequence;
|
|
// (6)创建jqGrid对象
|
|
$("#" + subgrid_table_id).dataGrid({
|
|
cellEdit: true,
|
|
url: "/WMS/WMSCreateItemLot/GetSubGridJson?ApplyNegCode=" + DNCode + "&Sequence=" + Sequence + "&Type=" + "7" + "&" + Math.random(), // (7)子表格数据对应的url,注意传入的contact.id参数
|
|
colModel: [
|
|
{ label: "主键", name: "ID", hidden: true, key: true },
|
|
{ label: "来源单据号", name: "TransCode", width: 200, align: 'left' },
|
|
{ label: '来源单据行', name: 'TransSequence', width: 200, align: 'left' },
|
|
{ label: '条码', name: 'LotNo', width: 200, align: 'left' },
|
|
{ label: '条码数量', name: 'Quantity', width: 200, align: 'left' },
|
|
{ label: '操作人', name: 'MUSERName', width: 200, align: 'left' },
|
|
{ label: '操作时间', name: 'MTIME', width: 200, align: 'left' },
|
|
],
|
|
//colModel: _Clos1,
|
|
//colModel: ColModelSub,
|
|
shrinkToFit: true,//宽度自适应
|
|
multiselect: true,
|
|
prmNames: { search: "search" },
|
|
viewrecords: true,
|
|
height: "100%",
|
|
rowNum: 20,
|
|
pager: subgrid_pager_id,
|
|
|
|
});
|
|
}
|
|
|
|
//开立得成品入库单 生成条码
|
|
function gridList9() {
|
|
var $gridList = $("#gridList");
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
OrderNumber: "",
|
|
Area: $("#txt_Area").val(),
|
|
InvCode: $("#txt_InvCode").val(),
|
|
InvName: "",
|
|
BatchCode: "",
|
|
WHCode: "",
|
|
Container: "2",
|
|
ProjectCode: "",
|
|
Brand: ""
|
|
}
|
|
$gridList.dataGrid({
|
|
url: "/WMS/WMSCreateItemLot/GetGridJsonKLCPRK" + "?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson) },
|
|
height: $(window).height() - 200,
|
|
width: $(window).width() - 300,
|
|
colModel: _Clos,
|
|
//colModel: [
|
|
// { label: "主键", name: "ID", hidden: true, key: true },
|
|
// { label: '单据号', name: 'RCVCode', width: 120, align: 'left' },
|
|
// { label: '行号', name: 'Sequence', width: 50, align: 'left' },
|
|
// { label: '仓库号', name: 'WHCode', width: 120, align: 'left' },
|
|
// { label: '料品编码', name: 'InvCode', width: 50, align: 'left' },
|
|
// { label: '物料描述', name: 'InvName', width: 120, align: 'left' },
|
|
// { label: '辅助描述', name: 'InvDesc', width: 50, align: 'left' },
|
|
// { label: '料品型号', name: 'InvStd', width: 150, align: 'left' },
|
|
// { label: '料品单位', name: 'InvStd', width: 50, align: 'left' },
|
|
// { label: '数量', name: 'Quantity', width: 100, align: 'left' },
|
|
// { label: '批次', name: 'BatchCode', width: 100, align: 'left' },
|
|
// { label: '已生成数量', name: 'LOTQTY', width: 100, align: 'left' },
|
|
// { label: '辅计量数量', name: 'Amount', width: 150, align: 'left' },
|
|
// { label: '入库数量', name: 'RCVQuantity', width: 60, align: 'left', },
|
|
// { label: '创建人', name: 'CreatePerson', width: 60, align: 'left', },
|
|
// { label: '创建时间', name: 'CreateDateTime', width: 100, align: 'left' },
|
|
//],
|
|
//colModel: ColModelMain,
|
|
width: "100%",
|
|
autowidth: true,
|
|
//shrinkToFit: true,
|
|
gridComplete: function () {
|
|
},
|
|
pager: "#gridPager",
|
|
sortname: 'RCVCode',
|
|
sortorder: "desc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
beforeSelectRow: function (rowid, e) {
|
|
},
|
|
subGrid: true, // (1)开启子表格支持
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid9(subgrid_id, rowid)
|
|
}
|
|
});
|
|
|
|
//$("#warehouse a.btn-default").click(function () {
|
|
// $("#warehouse a.btn-default").removeClass("active");
|
|
// $(this).addClass("active");
|
|
// $('#btn_search').trigger("click");
|
|
//});
|
|
//$("#btn_search").click(function () {
|
|
// var warehouse = $("#warehouse a.active").attr('data-value');
|
|
// var queryJson = {
|
|
// POCode: $("#txt_POCode").val(),
|
|
// OrderNumber: $("#txt_OrderNumber").val(),
|
|
// Area: $("#txt_Area").val(),
|
|
// InvCode: $("#txt_InvCode").val(),
|
|
// InvName: $("#txt_InvName").val(),
|
|
// BatchCode: $("#txt_BatchCode").val(),
|
|
// Container: $("#txt_Container :checked").val(),
|
|
// }
|
|
// $gridList.jqGrid('setGridParam', {
|
|
// page: 1,
|
|
// postData: { queryJson: JSON.stringify(queryJson) },
|
|
// }).trigger('reloadGrid');
|
|
//});
|
|
|
|
}
|
|
function bindSubGrid9(subgrid_id, rowid) {
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
var subgrid_table_id;
|
|
subgrid_table_id = subgrid_id + "_t"; // (3)根据subgrid_id定义对应的子表格的table的id
|
|
|
|
var subgrid_pager_id;
|
|
subgrid_pager_id = subgrid_id + "_pgr" // (4)根据subgrid_id定义对应的子表格的pager的id
|
|
|
|
// (5)动态添加子报表的table和pager
|
|
$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "' class='scroll'></table><div id='" + subgrid_pager_id + "' class='scroll'></div>");
|
|
var RCVCode = $("#gridList").jqGrid('getRowData', rowid).RCVCode;
|
|
var Sequence = $("#gridList").jqGrid('getRowData', rowid).Sequence;
|
|
// (6)创建jqGrid对象
|
|
$("#" + subgrid_table_id).dataGrid({
|
|
cellEdit: true,
|
|
url: "/WMS/WMSCreateItemLot/GetSubGridJson?ApplyNegCode=" + RCVCode + "&Sequence=" + Sequence + "&Type=" + "9" + "&" + Math.random(), // (7)子表格数据对应的url,注意传入的contact.id参数
|
|
colModel: [
|
|
{ label: "主键", name: "ID", hidden: true, key: true },
|
|
{ label: "来源单据号", name: "TransCode", width: 200, align: 'left' },
|
|
{ label: '来源单据行', name: 'TransSequence', width: 200, align: 'left' },
|
|
{ label: '条码', name: 'LotNo', width: 200, align: 'left' },
|
|
{ label: '条码数量', name: 'Quantity', width: 200, align: 'left' },
|
|
{ label: '操作人', name: 'MUSERName', width: 200, align: 'left' },
|
|
{ label: '操作时间', name: 'MTIME', width: 200, align: 'left' },
|
|
],
|
|
//colModel: _Clos1,
|
|
//colModel: ColModelSub,
|
|
shrinkToFit: true,//宽度自适应
|
|
multiselect: true,
|
|
prmNames: { search: "search" },
|
|
viewrecords: true,
|
|
height: "100%",
|
|
rowNum: 20,
|
|
pager: subgrid_pager_id,
|
|
|
|
});
|
|
}
|
|
|
|
//领料申请退料生成条码
|
|
function gridList12() {
|
|
var $gridList = $("#gridList");
|
|
var queryJson = {
|
|
POCode: $("#txt_POCode").val(),
|
|
InvCode: $("#txt_InvCode").val(),
|
|
InvName: "",
|
|
BatchCode: "",
|
|
Area: $("#txt_Area").val(),
|
|
Location: $("#txt_WHCode").val(),
|
|
Container: "2",
|
|
}
|
|
$gridList.dataGrid({
|
|
url: "/WMS/WMSCreateItemLot/GetGridJsonLLSQTL" + "?" + Math.random(),
|
|
postData: { queryJson: JSON.stringify(queryJson) },
|
|
height: $(window).height() - 200,
|
|
width: $(window).width() - 300,
|
|
colModel: _Clos,
|
|
width: "100%",
|
|
autowidth: true,
|
|
//shrinkToFit: true,
|
|
gridComplete: function () {
|
|
},
|
|
pager: "#gridPager",
|
|
sortname: 'ApplyNegCode',
|
|
sortorder: "desc",
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
beforeSelectRow: function (rowid, e) {
|
|
},
|
|
subGrid: true, // (1)开启子表格支持
|
|
subGridRowExpanded: function (subgrid_id, rowid) { // (2)子表格容器的id和需要展开子表格的行id,将传入此事件函数
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
bindSubGrid12(subgrid_id, rowid)
|
|
}
|
|
});
|
|
|
|
|
|
}
|
|
function bindSubGrid12(subgrid_id, rowid) {
|
|
$("#gridList").jqGrid("setSelection", rowid, false);
|
|
var subgrid_table_id;
|
|
subgrid_table_id = subgrid_id + "_t"; // (3)根据subgrid_id定义对应的子表格的table的id
|
|
|
|
var subgrid_pager_id;
|
|
subgrid_pager_id = subgrid_id + "_pgr" // (4)根据subgrid_id定义对应的子表格的pager的id
|
|
|
|
// (5)动态添加子报表的table和pager
|
|
$("#" + subgrid_id).html("<table id='" + subgrid_table_id + "' class='scroll'></table><div id='" + subgrid_pager_id + "' class='scroll'></div>");
|
|
var ApplyNegCode = $("#gridList").jqGrid('getRowData', rowid).ApplyNegCode;
|
|
var Sequence = $("#gridList").jqGrid('getRowData', rowid).Sequence;
|
|
// (6)创建jqGrid对象
|
|
$("#" + subgrid_table_id).dataGrid({
|
|
cellEdit: true,
|
|
url: "/WMS/WMSCreateItemLot/GetSubGridJson?ApplyNegCode=" + ApplyNegCode + "&Sequence=" + Sequence + "&Type=" + "12" + "&" + Math.random(), // (7)子表格数据对应的url,注意传入的contact.id参数
|
|
colModel: [
|
|
{ label: "主键", name: "ID", hidden: true, key: true },
|
|
{ label: "来源单据号", name: "TransCode", width: 200, align: 'left' },
|
|
{ label: '来源单据行', name: 'TransSequence', width: 200, align: 'left' },
|
|
{ label: '条码', name: 'LotNo', width: 200, align: 'left' },
|
|
{ label: '条码数量', name: 'Quantity', width: 200, align: 'left' },
|
|
{ label: '操作人', name: 'MUSERName', width: 200, align: 'left' },
|
|
{ label: '操作时间', name: 'MTIME', width: 200, align: 'left' },
|
|
],
|
|
//colModel: _Clos1,
|
|
//colModel: ColModelSub,
|
|
shrinkToFit: true,//宽度自适应
|
|
multiselect: true,
|
|
prmNames: { search: "search" },
|
|
viewrecords: true,
|
|
height: "100%",
|
|
rowNum: 20,
|
|
pager: subgrid_pager_id,
|
|
|
|
});
|
|
}
|
|
|
|
function btnDelete() {
|
|
debugger;
|
|
var Type = $("#selShow").val();
|
|
var sign = '';
|
|
var objCode = '';
|
|
var status = '';
|
|
var objList = $("#gridList").jqGrid('getGridParam', 'selarrrow');
|
|
if (objList.length <= 0) {
|
|
$.modalAlert("请先选择单据!", "warning");
|
|
return;
|
|
}
|
|
if (Type == 13 || Type == 14 || Type == 15 || Type == 16 || Type == 17) {
|
|
if (Type == '13') {
|
|
for (var i = 0; i < objList.length; i++) {
|
|
//var strValue = $("#gridList").jqGrid("getCell", objList[i], "LOTQTY")-0;//得到单元格数据
|
|
//var strValue2 = $("#gridList").jqGrid("getCell", objList[i], "RCVQuantity") - 0;//得到单元格数据
|
|
//if (strValue > 0 && strValue != strValue2) {
|
|
// $.modalAlertNew("WMS00117");
|
|
// return;
|
|
//}
|
|
if (objList[i] != undefined) {
|
|
var data = $("#gridList").jqGrid('getRowData', objList[i])
|
|
objCode += "'" + data.DNCode + "',";
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
else if (Type == '14') {
|
|
for (var i = 0; i < objList.length; i++) {
|
|
//var strValue = $("#gridList").jqGrid("getCell", objList[i], "LOTQTY") - 0;//得到单元格数据
|
|
//var strValue2 = $("#gridList").jqGrid("getCell", objList[i], "RCVQuantity") - 0;//得到单元格数据
|
|
//if (strValue > 0 && strValue != strValue2) {
|
|
// $.modalAlertNew("WMS00117");
|
|
// return;
|
|
//}
|
|
if (objList[i] != undefined) {
|
|
var data = $("#gridList").jqGrid('getRowData', objList[i])
|
|
objCode += "'" + data.RCVCode + "',";
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
else if (Type == '15') {
|
|
for (var i = 0; i < objList.length; i++) {
|
|
//var strValue = $("#gridList").jqGrid("getCell", objList[i], "LOTQTY") - 0;//得到单元格数据
|
|
//var strValue2 = $("#gridList").jqGrid("getCell", objList[i], "InQuantity") - 0;//得到单元格数据
|
|
//if (strValue > 0 && strValue != strValue2) {
|
|
// $.modalAlertNew("WMS00117");
|
|
// return;
|
|
//}
|
|
if (objList[i] != undefined) {
|
|
var data = $("#gridList").jqGrid('getRowData', objList[i])
|
|
objCode += "'" + data.InCode + "',";
|
|
|
|
}
|
|
}
|
|
|
|
}
|
|
else if (Type == '16') {
|
|
for (var i = 0; i < objList.length; i++) {
|
|
//var strValue = $("#gridList").jqGrid("getCell", objList[i], "LOTQTY") - 0;//得到单元格数据
|
|
//var strValue2 = $("#gridList").jqGrid("getCell", objList[i], "IssueNegQuantity") - 0;//得到单元格数据
|
|
//if (strValue > 0 && strValue != strValue2) {
|
|
// $.modalAlertNew("WMS00117");
|
|
// return;
|
|
//}
|
|
if (objList[i] != undefined) {
|
|
var data = $("#gridList").jqGrid('getRowData', objList[i])
|
|
objCode += "'" + data.ApplyNegCode + "',";
|
|
|
|
}
|
|
}
|
|
}
|
|
else {
|
|
for (var i = 0; i < objList.length; i++) {
|
|
//var strValue = $("#gridList").jqGrid("getCell", objList[i], "LOTQTY") - 0;//得到单元格数据
|
|
//var strValue2 = $("#gridList").jqGrid("getCell", objList[i], "SDNQuantity") - 0;//得到单元格数据
|
|
//if (strValue > 0 && strValue != strValue2) {
|
|
// if (strValue > 0) {
|
|
// $.modalAlertNew("WMS00117");
|
|
// return;
|
|
// }
|
|
if (objList[i] != undefined) {
|
|
var data = $("#gridList").jqGrid('getRowData', objList[i])
|
|
objCode += "'" + data.SDNCode + "',";
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
else {
|
|
for (var i = 0; i < objList.length; i++) {
|
|
//var strValue = $("#gridList").jqGrid("getCell", objList[i], "IsOccupy");//得到单元格数据
|
|
//if (strValue == "已占料") {
|
|
// $.modalAlertNew("WMS00116");
|
|
// return;
|
|
//}
|
|
var strValue1 = $("#gridList").jqGrid("getCell", objList[i], "Status");//得到单元格数据
|
|
if (strValue1 == "已过账") {
|
|
$.modalAlertNew("WMS00118");
|
|
return;
|
|
}
|
|
/*var rowData = $("#gridList").jqGrid('getRowData', rowId);获取数据*/
|
|
if (objList[i] != undefined) {
|
|
var data = $("#gridList").jqGrid('getRowData', objList[i])
|
|
objCode += "'" + data.Code + "',";
|
|
|
|
}
|
|
}
|
|
}
|
|
var msg = "";
|
|
objCode = objCode.substring(0, objCode.length - 1);
|
|
$.ajax({
|
|
url: "/WMS/DeleteReceipts/CheckReceipts?codes=" + objCode + "&" + "Type=" + Type,
|
|
dataType: "json",
|
|
type: "post",
|
|
async: false,
|
|
param: {
|
|
keyValue: JSON.stringify(objCode)
|
|
},
|
|
success: function (data) {
|
|
msg = data.state;
|
|
if (data.state == "success") {
|
|
}
|
|
else {
|
|
$.modalAlert(data.message, data.state);
|
|
return;
|
|
}
|
|
$.currentWindow().$("#gridList").trigger("reloadGrid");
|
|
}
|
|
});
|
|
if (msg == "success") {
|
|
$.ajax({
|
|
url: "/WMS/DeleteReceipts/DeleteReceipts?codes=" + objCode + "&" + "Type=" + Type,
|
|
dataType: "json",
|
|
type: "post",
|
|
async: false,
|
|
param: {
|
|
keyValue: JSON.stringify(objCode)
|
|
},
|
|
success: function (data) {
|
|
if (data.state == "success") {
|
|
$.modalMsg(data.message, data.state);
|
|
Seach();
|
|
} else {
|
|
$.modalAlert(data.message, data.state);
|
|
}
|
|
$.currentWindow().$("#gridList").trigger("reloadGrid");
|
|
}
|
|
});
|
|
|
|
}
|
|
|
|
//if (sign != '') {
|
|
// $.modalAlertNew('', sign,);
|
|
// return;
|
|
//}
|
|
}
|
|
|
|
|
|
function fullscreen() {
|
|
var docElm = document.documentElement;
|
|
if (docElm.requestFullscreen) {
|
|
docElm.requestFullscreen();
|
|
} else if (docElm.mozRequestFullScreen) {
|
|
docElm.mozRequestFullScreen();
|
|
} else if (docElm.webkitRequestFullScreen) {
|
|
docElm.webkitRequestFullScreen();
|
|
} else if (docElm.msRequestFullscreen) {
|
|
docElm.msRequestFullscreen();
|
|
}
|
|
$(window).bind('resize', function () {
|
|
$("#gridList").setGridWidth($(window).width());
|
|
}).trigger('resize');
|
|
$(window).bind('resize', function () {
|
|
$("#gridList").setGridHeight($(window).height());
|
|
}).trigger('resize');
|
|
}
|
|
</script>
|
|
|
|
|
|
<div class="topPanel" style="height:120px;">
|
|
<div class="toolbar">
|
|
<div class="btn-group">
|
|
<a id="NF-Delete" authorize="yes" style="margin-left:3px;" class="btn btn-primary" onclick="btnDelete()"><i class="fa fa-pencil-square-o"></i>删除单据</a>
|
|
<a class="btn btn-primary" onclick="$.reload()"><span class="glyphicon glyphicon-refresh"></span></a>
|
|
|
|
</div>
|
|
<script>$('.toolbar').authorizeButton()</script>
|
|
</div>
|
|
<div class="search">
|
|
<table>
|
|
<tr class="outWarehouse">
|
|
<td>
|
|
<label> 类型:</label>
|
|
</td>
|
|
<td>
|
|
<div class="input-group">
|
|
<select id="selShow" name="F_Target" class="form-control" style="width: 100px;" onchange="Seach()">
|
|
|
|
<option value="12" selected="selected">售后领料</option>
|
|
<option value="5" selected="selected">委外领料</option>
|
|
<option value="7" selected="selected">销售发货</option>
|
|
<option value="8" selected="selected">其它出库</option>
|
|
<option value="13" selected="selected">检验合格单</option>
|
|
<option value="14" selected="selected">机加工入库单</option>
|
|
<option value="15" selected="selected">成品中心退料单</option>
|
|
<option value="16" selected="selected">退料单</option>
|
|
<option value="17" selected="selected">销售退货单</option>
|
|
<option value="2" selected="selected" spellcheck="true">工单领料</option>
|
|
<option value="10" selected="selected">物料调拨</option>
|
|
</select>
|
|
</div>
|
|
</td>
|
|
|
|
|
|
<td style="text-align:right;"><label class="lglabel" for="txt_POCode"> 单据号</label>:</td>
|
|
<td>
|
|
<div class="input-group">
|
|
<input id="txt_POCode" type="text" class="form-control" style="width: 120px;">
|
|
<input id="PickID" type="text" class="form-control" style="width: 120px; display:none">
|
|
</div>
|
|
</td>
|
|
|
|
<td style="text-align:right" ;class="outWarehouse"><label class="lglabel" for="txt_POCode"> 区域</label>:</td>
|
|
<td class="outWarehouse">
|
|
<div class="input-group">
|
|
<input id="txt_Area" type="text" class="form-control" style="width: 120px;">
|
|
</div>
|
|
</td>
|
|
|
|
<td style="text-align:right;"><label class="lglabel" for="txt_POCode"> 仓库</label>:</td>
|
|
<td>
|
|
<div class="input-group">
|
|
<input id="txt_WHCode" type="text" class="form-control" style="width: 120px;">
|
|
</div>
|
|
</td>
|
|
|
|
<td style="text-align:right;"><label class="lglabel" for="txt_InvCode"> 料品编码</label>:</td>
|
|
<td>
|
|
<div class="input-group">
|
|
<input id="txt_InvCode" type="text" class="form-control" style="width: 120px;">
|
|
</div>
|
|
</td>
|
|
|
|
|
|
</tr>
|
|
<tr>
|
|
<td>
|
|
<span class="input-group-btn">
|
|
<button id="btn_search" type="button" class="btn btn-primary" onclick="Seach()"><i class="fa fa-search"></i></button>
|
|
</span>
|
|
</td>
|
|
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div class="gridPanel" id="gridPanel">
|
|
<span><strong>详细信息</strong></span>
|
|
<table id="gridList"></table>
|
|
|
|
</div>
|
|
<div class="gridPanel" id="page">
|
|
<table id="gridList"></table>
|
|
<div id="gridPager"></div>
|
|
</div>
|
|
@*<div class="gridPanel" id="gridPanel2">
|
|
<span><strong>合并信息</strong></span>
|
|
<table id="gridList2"></table>
|
|
</div>*@
|