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

101 lines
3.2 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
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. debugger;
  12. var Type = $.request("Type");
  13. $(function(){
  14. Init();
  15. })
  16. function Init() {
  17. var CodeName = '';
  18. debugger;
  19. if (Type == '1') {CodeName = '项目号';}
  20. if (Type == '2') { CodeName = '批次'; }
  21. if (Type == '3') { CodeName = '版本'; }
  22. if (Type == '4') { CodeName = '厂牌'; }
  23. if (Type == '5') { CodeName = '自由项1'; }
  24. if (Type == '6') { CodeName = '自由项2'; }
  25. if (Type == '7') { CodeName = '自由项3'; }
  26. if (Type == '8') { CodeName = '自由项4'; }
  27. if (Type == '9') { CodeName = '自由项5'; }
  28. if (Type == '10') { CodeName = '自由项6'; }
  29. if (Type == '11') { CodeName = '自由项7'; }
  30. if (Type == '12') { CodeName = '自由项8'; }
  31. if (Type == '13') { CodeName = '自由项9'; }
  32. if (Type == '14') { CodeName = '自由项10'; }
  33. document.getElementById("gridPanel").innerHTML = '<table id="gridList"></table><div id="gridPager"></div> ';//重置grid
  34. var Common = $("#txt_BatchCode").val();
  35. $("#gridList").dataGrid({
  36. url: "/WMS/ICSMTDOC/GetCode?Type=" + Type + "&Common=" + Common + "&" + Math.random(),
  37. height: $(window).height() - 20,
  38. width: $(window).width() - 300,
  39. colModel: [
  40. { label: CodeName, name: 'Code', width: 150, align: 'left' },
  41. ],
  42. pager: "#gridPager",
  43. sortorder: "desc",
  44. sortname: 'Code',
  45. viewrecords: true,
  46. multiselect: true,
  47. gridComplete: function () {
  48. }
  49. })
  50. };
  51. function submitForm() {
  52. var rows = $("#gridList").jqGrid('getGridParam', 'selarrrow');
  53. if (rows.length != 1) {
  54. $.modalAlertNew("WMS00079");
  55. return;
  56. }
  57. var rowdata = $("#gridList").jqGrid("getRowData", rows[0]);
  58. var obj = {
  59. Code: rowdata.Code,
  60. }
  61. return obj;
  62. }
  63. function Close() {
  64. $.modalClose();
  65. }
  66. </script>
  67. <div class="topPanel" style="height:50px">
  68. <div class="search">
  69. <table>
  70. <tr>
  71. <td>
  72. <label>批次号:</label>
  73. </td>
  74. <td>
  75. <div class="input-group">
  76. <input id="txt_BatchCode" type="text" class="form-control" placeholder="批次号" style="width: 120px;">
  77. </div>
  78. </td>
  79. <td>
  80. <a id="Search" authorize="yes" style="margin-left:3px;" class="btn btn-primary" onclick="Init()"><i class="fa fa-pencil-square-o"></i>查询</a>
  81. </td>
  82. </tr>
  83. <tr></tr>
  84. </table>
  85. </div>
  86. </div>
  87. <div class="gridPanel" id="gridPanel">
  88. <table id="gridList"></table>
  89. <div id="gridPager"></div>
  90. </div>