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.
94 lines
2.9 KiB
94 lines
2.9 KiB
|
|
@{
|
|
ViewBag.Title = "SeachInventory";
|
|
Layout = "~/Views/Shared/_Index.cshtml";
|
|
}
|
|
<link href="~/Content/js/select2/select2.min.css" rel="stylesheet" />
|
|
<link href="~/Content/js/dialog/dialog.css" rel="stylesheet" />
|
|
<script src="~/Content/js/datepicker/WdatePicker.js"></script>
|
|
<script src="~/Content/js/select2/select2.min.js"></script>
|
|
<script>
|
|
debugger;
|
|
|
|
$(function(){
|
|
Init();
|
|
})
|
|
function Init() {
|
|
document.getElementById("gridPanel").innerHTML = '<table id="gridList"></table><div id="gridPager"></div> ';//重置grid
|
|
var Invcode = $("#txt_Invcode").val();
|
|
$("#gridList").dataGrid({
|
|
url: "/WMS/ICSMTDOC/GetInvcode" + "?Invcode=" + Invcode + "&" + Math.random(),
|
|
height: $(window).height() - 20,
|
|
width: $(window).width() - 300,
|
|
colModel: [
|
|
{ label: '主键', name: 'ID', hidden: true, key: true },
|
|
{ label: '料品编码', name: 'InvCode', width: 150, align: 'left' },
|
|
{ label: '料品名称', name: 'InvName', width: 150, align: 'left' },
|
|
{ label: '规格型号', name: 'InvStd', width: 150, align: 'left' },
|
|
{ label: '单位', name: 'InvUnit', width: 100, align: 'left' },
|
|
{ label: '料品描述', name: 'InvDesc', width: 150, align: 'left' },
|
|
],
|
|
pager: "#gridPager",
|
|
sortorder: "desc",
|
|
sortname: 'InvCode',
|
|
viewrecords: true,
|
|
multiselect: true,
|
|
gridComplete: function () {
|
|
},
|
|
beforeSelectRow: function (rowid, e) {
|
|
$("#gridList").jqGrid('resetSelection');
|
|
return (true);
|
|
},
|
|
})
|
|
};
|
|
|
|
|
|
|
|
function submitForm() {
|
|
var rows = $("#gridList").jqGrid('getGridParam', 'selarrrow');
|
|
if (rows.length != 1) {
|
|
$.modalAlertNew("WMS00079");
|
|
return;
|
|
}
|
|
var rowdata = $("#gridList").jqGrid("getRowData", rows[0]);
|
|
|
|
var obj = {
|
|
InvCode: rowdata.InvCode,
|
|
}
|
|
return obj;
|
|
}
|
|
|
|
function Close() {
|
|
$.modalClose();
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
</script>
|
|
<div class="topPanel" style="height:50px">
|
|
<div class="search">
|
|
<table>
|
|
<tr>
|
|
<td>
|
|
<label>料品编码:</label>
|
|
</td>
|
|
<td>
|
|
<div class="input-group">
|
|
<input id="txt_Invcode" type="text" class="form-control" placeholder="料品编码" style="width: 120px;">
|
|
</div>
|
|
</td>
|
|
<td>
|
|
<a id="Search" authorize="yes" style="margin-left:3px;" class="btn btn-primary" onclick="Init()"><i class="fa fa-pencil-square-o"></i>查询</a>
|
|
</td>
|
|
</tr>
|
|
<tr></tr>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="gridPanel" id="gridPanel">
|
|
<table id="gridList"></table>
|
|
<div id="gridPager"></div>
|
|
</div>
|
|
|