安图前端代码

Xga.html 10KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  6. <link href="../css/init.css" rel="stylesheet" />
  7. <script src="../Script/Common/huayi.load.js"></script>
  8. <script src="../Script/Common/huayi.config.js"></script>
  9. <script src="../Script/Common/huayi.http.js"></script>
  10. <link href="../css/WorkOrder/Search.css" rel="stylesheet">
  11. <link rel="stylesheet" href="../js/zTree/zTreeStyle.css" />
  12. <link href="../js/bootstrap-select/css/bootstrap-select.css" rel="stylesheet" />
  13. <link rel="stylesheet" href="../css/WorkOrder/jquery.editable-select.css" />
  14. <link href="../css/init.css" rel="stylesheet" />
  15. <title>手工制单</title>
  16. <style>
  17. ul li {
  18. float: initial;
  19. list-style: none;
  20. }
  21. .common {
  22. width: 100%;
  23. text-align: center;
  24. padding: 10px 15px;
  25. }
  26. .common table {
  27. width: 100%;
  28. display: none;
  29. }
  30. .common table th {
  31. padding: 5px 8px 5px 0;
  32. text-align: right;
  33. /* width: 20%;*/
  34. }
  35. .common table td {
  36. padding: 6px 0 5px 10px;
  37. text-align: left;
  38. color: #717171;
  39. line-height: 200%;
  40. }
  41. .common table td textarea {
  42. width: 100%;
  43. vertical-align: middle;
  44. resize: none;
  45. outline: none;
  46. }
  47. .time-box {
  48. display: inline-block;
  49. position: relative;
  50. }
  51. i.tub {
  52. position: absolute;
  53. right: 8px;
  54. top: 8px;
  55. font-size: 18px;
  56. color: #00a0ca;
  57. }
  58. .treeList {
  59. top: 34px!important;
  60. border: 1px solid #e5e6e7!important;
  61. border-top: 0;
  62. height: auto!important;
  63. }
  64. #TreeDemo li {
  65. float: initial;
  66. }
  67. #typeclass {
  68. background: #fff;
  69. }
  70. .form-group {
  71. margin-bottom: 0;
  72. }
  73. .bootstrap-select>.dropdown-toggle.bs-placeholder {
  74. background-color: #ffffff!important;
  75. border-color: #e5e6e7!important;
  76. }
  77. .filter-option {
  78. color: #676b6d;
  79. }
  80. .bootstrap-select>.dropdown-toggle.btn-default {
  81. background-color: #ffffff!important;
  82. border-color: #e5e6e7!important;
  83. color: #555;
  84. }
  85. .testInput-list {
  86. position: absolute;
  87. z-index: 999;
  88. border: 1px solid rgb(204, 204, 204);
  89. background-color: rgb(255, 255, 255);
  90. z-index: 99999;
  91. padding-left: 0;
  92. width: 97.6%;
  93. display: none;
  94. }
  95. .testInput-list li {
  96. padding: 5px;
  97. }
  98. .testInput-list li:hover {
  99. background-color: #E43926;
  100. color: #fff;
  101. }
  102. #testInput1,#testInput2,#testInput3,#testInput4{
  103. outline:none;
  104. border: 1px solid #ccc;
  105. padding-left: 10px;
  106. outline-color :#fff;
  107. }
  108. </style>
  109. </head>
  110. <body class="gray-bg">
  111. <div class="clearfix wrapper wrapper-content animated fadeInRight">
  112. <div class="common">
  113. <!--客服部-->
  114. <table class="customerService">
  115. <tbody>
  116. <tr>
  117. <th>姓名:</th>
  118. <td>
  119. <div class="form-group">
  120. <input type="text" class="form-control" id="name" />
  121. </div>
  122. </td>
  123. <th>电话:</th>
  124. <td>
  125. <div class="form-group">
  126. <input type="text" class="form-control" id="tel" readonly="readonly" />
  127. </div>
  128. </td>
  129. <th>来电单位:</th>
  130. <td style="position: relative;">
  131. <!--<select name="" id="testInput1" class="">
  132. </select>-->
  133. <input id="testInput1" type="text" style="width:100%;" />
  134. <ul class="testInput-list">
  135. <li></li>
  136. </ul>
  137. </td>
  138. </tr>
  139. <tr>
  140. <th>反馈单位:</th>
  141. <td style="position: relative;">
  142. <input id="testInput2" type="text" style="width:100%;" style="display: none;" />
  143. <ul class="testInput-list">
  144. <li></li>
  145. </ul>
  146. </td>
  147. <th>工单来源:</th>
  148. <td>
  149. <div class="form-group">
  150. <select name="" class="form-control" id="DicValueList"> </select>
  151. </div>
  152. </td>
  153. <th>工单状态:</th>
  154. <td>
  155. <div class="form-group">
  156. <select name="" class="form-control" id="State"> </select>
  157. <input id="States" type="hidden">
  158. </div>
  159. </td>
  160. </tr>
  161. <tr>
  162. <th>工单类型:</th>
  163. <td>
  164. <div class="time-box">
  165. <i class="tub fa fa-caret-down down" style="color: #676b6d;"></i>
  166. <input class="form-control" type="text" id="typeclass" readonly="readonly">
  167. <input type="hidden" id="typeclassId" />
  168. <div class="addTree treeList">
  169. <ul id="TreeDemo" class="ztree">
  170. </ul>
  171. </div>
  172. </div>
  173. </td>
  174. </tr>
  175. <tr>
  176. <th>反馈内容及处理结果:</th>
  177. <td colspan="5">
  178. <textarea name="" rows="5" cols="" placeholder="" id="feedBackCon"></textarea>
  179. </td>
  180. </tr>
  181. <tr>
  182. <th>快递信息:</th>
  183. <td colspan="5">
  184. <textarea name="" rows="" cols="" id="express"></textarea>
  185. </td>
  186. </tr>
  187. <tr>
  188. <th>备注一:</th>
  189. <td colspan="5">
  190. <textarea name="" rows="" cols="" id="remark1"></textarea>
  191. </td>
  192. </tr>
  193. <tr>
  194. <th>备注二:</th>
  195. <td colspan="5">
  196. <textarea name="" rows="" cols="" id="remark2"></textarea>
  197. </td>
  198. </tr>
  199. <tr>
  200. <th>备注三:</th>
  201. <td colspan="5">
  202. <textarea name="" rows="" cols="" id="remark3"></textarea>
  203. </td>
  204. </tr>
  205. <tr>
  206. <td colspan="6" style="text-align: center;">
  207. <button class="btns customerSubmit">保&nbsp;存</button>
  208. </td>
  209. </tr>
  210. </tbody>
  211. </table>
  212. <!--市场部-->
  213. <table class="market">
  214. <tbody>
  215. <tr>
  216. <th>姓名:</th>
  217. <td>
  218. <div class="form-group">
  219. <input type="text" class="form-control" id="name_market" />
  220. </div>
  221. </td>
  222. <th>电话:</th>
  223. <td>
  224. <div class="form-group">
  225. <input type="text" class="form-control" id="tel_market" />
  226. </div>
  227. </td>
  228. <th>来电单位:</th>
  229. <!--<td>
  230. <select class="form-control selectpicker" id="comeCall_dep_market" data-live-search="true">
  231. <option value="">请选择来电单位</option>
  232. </select>
  233. </td>-->
  234. <td style="position: relative;">
  235. <input id="testInput3" type="text" style="width:100%;" style="display: none;" />
  236. <ul class="testInput-list">
  237. <li></li>
  238. </ul>
  239. </td>
  240. </tr>
  241. <tr>
  242. <th>反馈单位:</th>
  243. <!--<td>
  244. <select class="form-control selectpicker" id="feedbackDep_market" data-live-search="true">
  245. <option value="">请选择反馈单位</option>
  246. </select>
  247. </td>-->
  248. <td style="position: relative;">
  249. <input id="testInput4" type="text" style="width:100%;" style="display: none;" />
  250. <ul class="testInput-list">
  251. <li></li>
  252. </ul>
  253. </td>
  254. </tr>
  255. <tr>
  256. <th>备注内容:</th>
  257. <td colspan="5">
  258. <textarea name="" rows="" cols="" id="remark_market"></textarea>
  259. </td>
  260. </tr>
  261. <tr>
  262. <td colspan="6" style="text-align: center;">
  263. <button class="btns marketSubmit">保&nbsp;存</button>
  264. </td>
  265. </tr>
  266. </tbody>
  267. </table>
  268. </div>
  269. <input type="hidden" id="CallID"/>
  270. </div>
  271. <script src="../js/zTree/jquery.ztree.core.js"></script>
  272. <script src="../My97DatePicker/WdatePicker.js"></script>
  273. <script src="../js/bootstrap-select/js/bootstrap-select.js"></script>
  274. <script src="../js/WorkOrder/xgWork.js"></script>
  275. <script src="../js/WorkOrder/jquery.editable-select.js"></script>
  276. <script>
  277. Select($("#testInput1"));
  278. Select($("#testInput2"));
  279. Select($("#testInput3"));
  280. Select($("#testInput4"));
  281. var id=helper.request.queryString("id");
  282. console.log(id);
  283. //获取详情
  284. $.getJSON(huayi.config.callcenter_url+'WorkOrder/GetWorkOrder', { "orderid": id, "token": $.cookie("token") }, function (result) {
  285. if (result.state.toLowerCase() == "success") {
  286. if (result.data.data.length > 0) {
  287. var data = result.data.data[0];
  288. var state=data.State;
  289. var state_;
  290. $("#xq_gdlx").text(data.GDLXName);
  291. $("#xq_cjsj").text(data.CreateTime);
  292. // $("#xq_gdzt").html(GetStateName(data.State));
  293. $("#name").val(data.Customer);
  294. $("#tel").val(data.CustomerTel);
  295. $("#testInput1").val(data.Address);
  296. $("#testInput2").val(data.Source);
  297. $("#typeclass").val(data.GDLXName);
  298. $("#feedBackCon").text(data.Detail);
  299. $("#express").text(data.Files);
  300. $("#remark1").text(data.City);
  301. $("#remark2").text(data.Province);
  302. $("#remark3").text(data.County);
  303. if(state==0){
  304. state_=471;
  305. }else{
  306. state_=472;
  307. }
  308. console.log(state_)
  309. $("#State").val(state_+'');
  310. $("#DicValueList").val(data.Type+'');
  311. $("#typeclassId").val(data.TypeClass);
  312. $("#States").val(data.State);
  313. }
  314. }
  315. })
  316. function Select(obj) {
  317. obj.click(function (event) {
  318. event.preventDefault();
  319. });
  320. obj.focus(function() { //
  321. //失去焦点后触发的事件
  322. obj.parent().find('.testInput-list').show();
  323. BindLDdep();
  324. });
  325. obj.bind("input propertychange", function() {
  326. var value = $(this).val();
  327. obj.parent().find('.testInput-list').show();
  328. BindLDdep(value)
  329. });
  330. function BindLDdep(str) {
  331. $('.testInput-list').empty();
  332. $.ajax({
  333. type: "get",
  334. url: huayi.config.callcenter_url + "Customer/BindLDdep",
  335. dataType: 'json',
  336. async: true,
  337. data: {
  338. keypara: str,
  339. token: $.cookie("token")
  340. },
  341. success: function(data) {
  342. var Count = data.data.dep;
  343. console.log(Count);
  344. var html = '';
  345. $(Count).each(function(i, n) {
  346. html = '<li value="' + n + '" id="td'+i+'">' + n + '</li>';
  347. $(html).appendTo($('.testInput-list'));
  348. });
  349. $('.testInput-list>li').click(function() {
  350. obj.val($(this).html());
  351. console.log($(this).html());
  352. $('.testInput-list').hide();
  353. })
  354. }
  355. });
  356. };
  357. //
  358. }
  359. //请求单位
  360. $(document).ready(function(){
  361. $(document).click(function(e) {
  362. if(!$(e.target).is($('.testInput-list>li'))&&!$(e.target).is($('#testInput1'))&&!$(e.target).is($('#testInput2'))&&!$(e.target).is($('#testInput3'))&&!$(e.target).is($('#testInput4'))) {
  363. $('.testInput-list').hide();
  364. }
  365. })
  366. })
  367. </script>
  368. </body>
  369. </html>