永城市12345 (县级市)- 来源于虞城县12345 - 所有县级统一API

Work-paidan.html 7.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280
  1. <!doctype html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>我要投诉</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1,maximum-scale=1,user-scalable=no">
  7. <meta name="apple-mobile-web-app-capable" content="yes">
  8. <meta name="apple-mobile-web-app-status-bar-style" content="black">
  9. <link href="../css/mui.min.css" rel="stylesheet" />
  10. <link href="../css/mui.poppicker.css" rel="stylesheet" />
  11. <link rel="stylesheet" type="text/css" href="../css/mui.picker.min.css" />
  12. <style>
  13. .mui-bar-popover {
  14. width: 30%;
  15. }
  16. .mui-popover.mui-bar-popover .mui-table-view {
  17. width: 100%;
  18. }
  19. .mui-table-view .mui-table-view-cell>a:not(.mui-btn) {
  20. text-align: center;
  21. }
  22. .mui-table-view-cell {
  23. padding: 1px 15px!important;
  24. }
  25. .san {
  26. font-size: 14px;
  27. margin-right: 5px
  28. }
  29. .nav_a {
  30. border-right: 1px solid #ccc;
  31. }
  32. .radio_box {
  33. display: inline-block;
  34. }
  35. .mui-radio input[type=radio]:before {
  36. font-size: 20px;
  37. vertical-align: middle;
  38. }
  39. .mui-radio.mui-left input[type=radio] {
  40. line-height: 24px!important;
  41. }
  42. .mui-radio.mui-left label {
  43. padding-right: 1px!important;
  44. padding-left: 51px!important;
  45. }
  46. .ztext {
  47. width: 100%;
  48. margin: 0;
  49. border: 0;
  50. }
  51. .action {
  52. padding: 5px 15px;
  53. }
  54. .type_down {
  55. float: right!important;
  56. display: inline-block!important;
  57. vertical-align: middle!important;
  58. line-height: 42px;
  59. }
  60. .type_con {
  61. width: 55%!important;
  62. float: left!important;
  63. vertical-align: middle!important;
  64. display: inline-block!important;
  65. padding: 10px 0!important;
  66. }
  67. .label {
  68. width: 30%!important;
  69. padding: 11px 0px!important;
  70. }
  71. .get_yzm {
  72. padding: 5px!important;
  73. width: auto!important;
  74. }
  75. .yzm_con {
  76. float: left!important;
  77. width: 40%!important;
  78. }
  79. .mui-bar-nav {
  80. background-color: #00a1cb;
  81. }
  82. .mui-input-row label {
  83. text-align: -webkit-right;
  84. }
  85. .mui-btn-block {
  86. padding: 10px;
  87. width: 100%;
  88. }
  89. label {
  90. font-size: 16px;
  91. color: #fe6604;
  92. }
  93. </style>
  94. </head>
  95. <body>
  96. <header class="mui-bar mui-bar-nav " style="padding-right: 15px;height: 50px;color: #fff;">
  97. <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left" style="color: #fff;"></a>
  98. <h1 class="mui-center mui-title" style="color: #fff;">派单</h1>
  99. </header>
  100. <div class="mui-content">
  101. <ul class="mui-table-view">
  102. <li class="mui-table-view-cell">
  103. <div class="mui-input-row">
  104. <label class="label">调度意见:</label>
  105. <textarea name="" rows="" cols="" id="DDYJ"></textarea>
  106. </div>
  107. </li>
  108. <li class="mui-table-view-cell" id="showUserPicker">
  109. <div class="mui-input-row">
  110. <label class="label">办理时限:</label>
  111. <input id='demo1' data-options='{"type":"datetime","beginYear":year,"beginMonth":month,"beginDay":day}' type="text" class="mui-input-clear btn contact" />
  112. </div>
  113. </li>
  114. <li class="mui-table-view-cell" id="DW">
  115. <div class="mui-input-row">
  116. <label class="label">交办单位:</label>
  117. <input type="text" id='DWResult' class="ui-alert type_con" data-index="" readonly="readonly" />
  118. <a href=""><span class="type_down mui-icon mui-icon-arrowdown mui-pull-right"></span></a>
  119. </div>
  120. </li>
  121. </ul>
  122. <!--<button type="button" class="mui-btn mui-btn-primary mui-btn-block block_button">提交</button>-->
  123. <div style="padding: 10px;">
  124. <button type="button" data-loading-text="提交中" class="mui-btn mui-btn-primary mui-btn-block block_button submit">提交</button>
  125. </div>
  126. </div>
  127. <script src="../js/mui.min.js?"></script>
  128. <script src="../js/mui.poppicker.js"></script>
  129. <script src="../js/mui.picker.min.js"></script>
  130. <script src="../js/zepto.js"></script>
  131. <script src="../js/huayi.config.js"></script>
  132. <script type="text/javascript">
  133. mui.init({
  134. swipeBack: false,
  135. })
  136. mui.plusReady(function() {
  137. var year=new Date().getFullYear();
  138. var month=new Date().getMonth();
  139. var day=new Date().getDate();
  140. var wv = plus.webview.currentWebview();
  141. var token = wv.token;
  142. var isdeals = wv.name;
  143. var btns = mui('.btn'); 
  144. btns.each(function(i, btn) {  
  145. btn.addEventListener('tap', function() {   
  146. var dtPicker = new mui.DtPicker({    
  147. type: "date", //设置日历初始视图模式
  148. beginDate: new Date(year, month, day),//设置开始日期
  149.   
  150. });  
  151. dtPicker.show(function(e) {
  152. $("#demo1").val(e)
  153. }); 
  154. }, false);
  155. })
  156. //提交按钮
  157. $('.submit').on('tap', function() {
  158. var DDYJ = $("#DDYJ").val();
  159. var demo1 = $("#demo1").val();
  160. var DWResult = $("#DWResult").val();
  161. if(!DDYJ) {
  162. plus.nativeUI.toast('调度意见不能为空');
  163. } else if(!demo1) {
  164. plus.nativeUI.toast('输入办理时限');
  165. } else if(!DWResult) {
  166. plus.nativeUI.toast('输入交办单位');
  167. } else {
  168. var btnArray = ['取消', '确定'];
  169. mui.confirm('是否交办工单', '提示', btnArray, function(e) {
  170. if(e.index == 1) {
  171. mui.ajax(huayi.config.callcenter_url + 'WorkOrder/SplitWorkOrder', {
  172. data: {
  173. workorderid: isdeals,
  174. maindeptid: $("#DWResult").attr('data-index'), //单位
  175. limittime: $("#demo1").val(), //办理时限
  176. assignedopinion: $("#DDYJ").val(), //交办意见
  177. state: 1,
  178. token: token
  179. },
  180. dataType: 'json', //服务器返回json格式数据
  181. type: 'post', //HTTP请求类型
  182. timeout: 10000, //超时时间设置为10秒;
  183. success: function(data) {
  184. plus.nativeUI.toast('成功');
  185. $("#DDYJ").val('');
  186. $("#demo1").val('');
  187. $("#DWResult").val('');
  188. var wobj = plus.webview.getWebviewById("Work-listDCL");
  189. wobj.reload(true);
  190. },
  191. error: function(xhr, type, errorThrown) {
  192. plus.nativeUI.toast('失败');
  193. }
  194. });
  195. } else {
  196. plus.nativeUI.toast('取消申请');
  197. }
  198. })
  199. }
  200. })
  201. //交办单位
  202. var dwList;
  203. $.ajax({
  204. type: "get",
  205. url: huayi.config.callcenter_url + 'Department/GetDeptListtree',
  206. async: false,
  207. data: {
  208. token: token
  209. },
  210. dataType: 'json',
  211. success: function(data) {
  212. console.log(data)
  213. dwList = data.data;
  214. alert(data)
  215. }
  216. });
  217. function Submit() {
  218. mui.alert('64');
  219. }
  220. (function($, doc) {
  221. $.init();
  222. $.ready(function() {
  223. //交办单位
  224. var ZTiPickers = new $.PopPicker({
  225. layer: 3
  226. });
  227. ZTiPickers.setData(dwList);
  228. var ZXs = doc.getElementById('DW');
  229. var ZXResults = doc.getElementById('DWResult');
  230. ZXs.addEventListener('tap', function(event) {
  231. ZTiPickers.show(function(items) {
  232. console.log(items)
  233. ZXResults.value = items[2].text;
  234. ZXResults.setAttribute("data-index", items[2].id);
  235. //返回 false 可以阻止选择框的关闭
  236. //return false;
  237. });
  238. }, false);
  239. })
  240. })(mui, document);
  241. });
  242. </script>
  243. </body>
  244. </html>