纽威
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.

146 lines
5.5 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. 
  2. @{
  3. ViewBag.Title = "SeachInventory";
  4. Layout = "~/Views/Shared/_Index.cshtml";
  5. }
  6. <link href="~/Content/js/select2/select2.min.css" rel="stylesheet" />
  7. <link href="~/Content/js/dialog/dialog.css" rel="stylesheet" />
  8. <script src="~/Content/js/datepicker/WdatePicker.js"></script>
  9. <script src="~/Content/js/select2/select2.min.js"></script>
  10. <script>
  11. var _Clos = new Array();
  12. var WorkPoint = $.request("workpoint");
  13. var InvCode = $.request("InvCode");
  14. $(function () {
  15. SetCols();
  16. Init();
  17. })
  18. function SetCols() {
  19. $.ajax({
  20. url: "/Print/SelectColumnName?" + Math.random(),
  21. dataType: "json",
  22. async: false,
  23. success: function (data) {
  24. var cols = new Array();
  25. var collast = { label: 'ID', name: 'ID', width: 100, align: 'left' };
  26. cols.push(collast);
  27. var collast = { label: '仓库', name: 'WHCode', width: 100, align: 'left' };
  28. cols.push(collast);
  29. var collast = { label: '工单号', name: 'MOCode', width: 100, align: 'left' };
  30. cols.push(collast);
  31. var collast = { label: '行号', name: 'Sequence', width: 100, align: 'left' };
  32. cols.push(collast);
  33. var collast = { label: '子件行', name: 'ZJHH', width: 100, align: 'left' };
  34. cols.push(collast);
  35. var collast = { label: '批次', name: 'BatchCode', width: 100, align: 'left' };
  36. cols.push(collast);
  37. var collast = { label: '数量', name: 'Quantity', hidden: true };
  38. cols.push(collast);
  39. var collast = { label: '辅计量数量', name: 'Amount', hidden: true };
  40. cols.push(collast);
  41. var collast = { label: 'ExtensionID', name: 'ExtensionID', hidden: true };
  42. cols.push(collast);
  43. if (data != null && data.length > 0) {
  44. DateList = data;
  45. for (var i = 0; i < data.length; i++) {
  46. var ColName = data[i].ColName;
  47. var ColCode = data[i].ColCode;
  48. var obj = new Array();
  49. obj = {
  50. label: ColName,
  51. name: ColCode,
  52. width: 80,
  53. align: "left"
  54. }
  55. cols.push(obj);
  56. }
  57. }
  58. _Clos = cols;
  59. }
  60. });
  61. }
  62. function Init() {
  63. document.getElementById("gridPanel").innerHTML = ' <span><strong>详细信息</strong></span> <table id="gridList"></table> ';//重置grid
  64. var invcode = $("#txt_Invcode").val();
  65. $("#gridList").dataGrid({
  66. url: "/WMS/ProductionIssue/GetICSMOPickLog" + "?invcode=" + InvCode + "&workpoint=" + WorkPoint + "&" + Math.random(),
  67. height: $(window).height() - 20,
  68. width: $(window).width() - 300,
  69. colModel: _Clos,
  70. // colModel: [
  71. // { label: 'ID', name: 'ID', width: 100, align: 'left' },
  72. // { label: '仓库', name: 'WHCode', width: 100, align: 'left' },
  73. // { label: '工单号', name: 'MOCode', width: 100, align: 'left' },
  74. // { label: '行号', name: 'Sequence', width: 100, align: 'left' },
  75. // { label: '子件行', name: 'ZJHH', width: 100, align: 'left' },
  76. // { label: '批次', name: 'BatchCode', width: 100, align: 'left' },
  77. // { label: '数量', name: 'Quantity', hidden: true },
  78. // { label: '辅计量数量', name: 'Amount', hidden: true },
  79. //],
  80. pager: "#gridPager",
  81. sortorder: "desc",
  82. sortname: 'InvCode',
  83. viewrecords: true,
  84. multiselect: true,
  85. gridComplete: function () {
  86. }
  87. })
  88. }
  89. function submitForm() {
  90. var rows = $("#gridList").jqGrid('getGridParam', 'selarrrow');
  91. if (rows.length != 1) {
  92. $.modalAlertNew("WMS00079");
  93. return;
  94. }
  95. var rowdata = $("#gridList").jqGrid("getRowData", rows[0]);
  96. var obj = {
  97. ID: rowdata.ID,
  98. MOCode: rowdata.MOCode,
  99. Sequence: rowdata.Sequence,
  100. ZJHH: rowdata.ZJHH,
  101. BatchCode: rowdata.BatchCode,
  102. Quantity: rowdata.Quantity,
  103. Amount: rowdata.Amount,
  104. }
  105. return obj;
  106. }
  107. function Close() {
  108. $.modalClose();
  109. }
  110. function reloadData() {
  111. }
  112. </script>
  113. <div class="topPanel" style="height:50px">
  114. @*<div class="search">
  115. <table>
  116. <tr>
  117. <td>
  118. <label>物料编码:</label>
  119. </td>
  120. <td>
  121. <div class="input-group">
  122. <input id="txt_Invcode" type="text" class="form-control" placeholder="物料编码" style="width: 120px;">
  123. </div>
  124. </td>
  125. <td>
  126. <a id="Search" authorize="yes" style="margin-left:3px;" class="btn btn-primary" onclick="Init()"><i class="fa fa-pencil-square-o"></i>查询</a>
  127. </td>
  128. </tr>
  129. <tr></tr>
  130. </table>
  131. </div>*@
  132. </div>
  133. <div class="gridPanel" id="gridPanel">
  134. <table id="gridList"></table>
  135. <div id="gridPager"></div>
  136. </div>