Нет описания

haveDoneToAuditOperationAll.html 3.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8" />
  5. <script src="../Script/Common/huayi.load.js"></script>
  6. <script src="../Script/Common/huayi.config.js"></script>
  7. <link rel="stylesheet" href="../css/bootstrap-select.css" />
  8. <link rel="stylesheet" href="../css/init.css" />
  9. <title>添加</title>
  10. <style>
  11. .Common table th {
  12. width: 100px
  13. }
  14. .auditState {
  15. display: none;
  16. }
  17. </style>
  18. </head>
  19. <body>
  20. <div class="wrapper wrapper-content animated fadeInRight">
  21. <div style="padding: 10px" class="tj_content clearFix">
  22. <div class="Common">
  23. <table>
  24. <tr>
  25. <th>审核状态:</th>
  26. <td colspan="7">
  27. <select name="auditState" class="form-control" id="auditState">
  28. <option value="0">审核通过</option>
  29. <option value="1">审核不通过</option>
  30. <option value="2">审核通过转办</option>
  31. </select>
  32. </td>
  33. </tr>
  34. <tr class="auditState">
  35. <th>审核说明:</th>
  36. <td colspan="7">
  37. <textarea id="cbreason" class="form-control" name="" rows="" cols="" style=""></textarea>
  38. </td>
  39. </tr>
  40. <tr>
  41. <td colspan="8" style="text-align: center">
  42. <button class="btns save">保存</button>
  43. </td>
  44. </tr>
  45. </table>
  46. </div>
  47. </div>
  48. </div>
  49. <script>
  50. var wid = helper.request.queryString("wid");
  51. var nexttype;
  52. $(document).ready(function () {
  53. $(".save").click(function () {
  54. Add()
  55. });
  56. $("#auditState").change(function(){
  57. if (Number($("#auditState").val())) {
  58. $(".auditState").show()
  59. } else {
  60. $(".auditState").hide()
  61. $("#cbreason").val('')
  62. }
  63. // Number($("#auditState").val()) ? $(".auditState").show():$(".auditState").hide()
  64. })
  65. });
  66. //修改工单
  67. function Add() {
  68. nexttype =Number($("#auditState").val())
  69. if (nexttype === 0) {
  70. layer.confirm('确认审核通过吗?', {
  71. btn: ['是', '否'] //按钮
  72. }, function () {
  73. layer.confirm('是否发送短信?', {
  74. btn: ['是', '否'] //按钮
  75. }, function () {
  76. toExamineWorkOrder(1,nexttype)
  77. },function(){
  78. toExamineWorkOrder(0,nexttype)
  79. });
  80. });
  81. } else if(nexttype===1 || nexttype ===2){
  82. $("#cbreason").show()
  83. toExamineWorkOrder()
  84. }
  85. }
  86. function toExamineWorkOrder(issmsAudit){
  87. $.post(huayi.config.callcenter_url + 'WorkOrder/ToExamineWorkOrder', {
  88. workorderid: wid,
  89. nexttype: nexttype, // 0审核通过 1审核不通过 2审核通过转办
  90. issms:issmsAudit,
  91. cbreason: $("#cbreason").val(),
  92. "token": $.cookie("token")
  93. }, function(result) {
  94. result = JSON.parse(result);
  95. if(result.state.toLowerCase() == "success") {
  96. var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
  97. parent.layer.close(index); //再执行关闭
  98. parent.$("#orderlist").bootstrapTable("refresh");
  99. parent.layer.msg("操作成功");
  100. }
  101. })
  102. }
  103. </script>
  104. </body>
  105. </html>