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.

99 lines
3.3 KiB

3 weeks ago
  1. 
  2. @{
  3. ViewBag.Title = "Index";
  4. Layout = "~/Views/Shared/_Form.cshtml";
  5. }
  6. <script>
  7. debugger;
  8. var Type = $.request("OpraterType");
  9. var LotNOList = decodeURI($.request("LotNOList"));
  10. var Mtime = new Date().getFullYear() + "-" + (new Date().getMonth() + 1) + "-" + new Date().getDate();
  11. var WorkPoints = '@NFine.Code.OperatorProvider.Provider.GetCurrent().Location'
  12. $(function () {
  13. if (Type == "1") {
  14. $("#reason").html("冻结原因");
  15. //$(".batchCode").css('display', 'none');
  16. //$(".batchCode1").css('display', 'none');
  17. }
  18. else {
  19. debugger;
  20. $("#reason").html("解冻原因");
  21. $("#batchCode").css('display', 'none');
  22. $("#batchCode1").css('display', 'none');
  23. }
  24. });
  25. //提交
  26. function submitForm() {
  27. var Memo = $("#Memo").val();
  28. if (Memo == "") {
  29. $.modalAlertNew("WMS00122");
  30. return;
  31. }
  32. if (Type == "1") {
  33. var batchCode = $("#text_batchCode").val();
  34. var str = '';
  35. if (batchCode == "") {
  36. $.modalAlertNew("WMS00125");
  37. return;
  38. }
  39. $.ajax({
  40. url: "/KBSWMS/ICSLotFreezeDH/GetBathCode?BatchCode=" + batchCode + "&"+ Math.random(),
  41. dataType: "json",
  42. async: false,
  43. success: function (data) {
  44. debugger;
  45. str = data.message;
  46. }
  47. });
  48. $.modalConfirm(str+"确定冻结选中条码吗?", function (r) { //GetBathCode
  49. if (r) {
  50. $.submitForm({
  51. url: "/KBSWMS/ICSLotFreezeDH/Freeze?LotNOList=" + LotNOList + "&Memo=" + Memo + "&BatchCode=" + batchCode + "&" + Math.random(),
  52. success: function () {
  53. $.currentWindow().$("#gridList").trigger("reloadGrid");
  54. }
  55. })
  56. }
  57. });
  58. }
  59. else {
  60. $.modalConfirm("确定对选中条码做解除冻结操作吗?", function (r) {
  61. if (r) {
  62. $.submitForm({
  63. url: "/KBSWMS/ICSLotFreezeDH/UnFreeze?LotNOList=" + LotNOList + "&Memo=" + Memo + "&" + Math.random(),
  64. success: function () {
  65. $.currentWindow().$("#gridList").trigger("reloadGrid");
  66. }
  67. })
  68. }
  69. });
  70. }
  71. }
  72. </script>
  73. <form id="form1">
  74. <div style="padding-top: 20px; margin-right: 20px;">
  75. <table class="form">
  76. <tr>
  77. <th id="reason" class="formTitle">原因</th>
  78. <td class="formValue">
  79. <textarea id="Memo" name="Memo" class="form-control" placeholder="请输入原因"></textarea>
  80. </td>
  81. </tr>
  82. <tr>
  83. <th id="batchCode" class="formTitle">批次</th>
  84. <td id ="batchCode1"class="formValue">
  85. <textarea id="text_batchCode" name="text_batchCode" class="form-control" placeholder="请输入批次"></textarea>
  86. </td>
  87. </tr>
  88. </table>
  89. </div>
  90. </form>