济源12345的前端

ZXDCL.html 29KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>待处理工单</title>
  6. <script src="../Script/Common/huayi.load.js"></script>
  7. <link rel="stylesheet" href="../css/bootstrap-select.css">
  8. <script src="../Script/Common/huayi.config.js"></script>
  9. <link rel="stylesheet" href="../js/zTree/zTreeStyle.css" />
  10. <link rel="stylesheet" href="../css/init.css" />
  11. <style>
  12. #sqzx th {
  13. padding: 5px 8px 5px 0;
  14. text-align: right;
  15. }
  16. .select {
  17. width: 150px;
  18. background-color: #FFF;
  19. background-image: none;
  20. border: 1px solid #ccc;
  21. border-radius: 1px;
  22. color: inherit;
  23. padding: 6px 12px;
  24. }
  25. #sex {
  26. background-color: #FFF;
  27. background-image: none;
  28. border: 1px solid #ccc;
  29. border-radius: 1px;
  30. color: inherit;
  31. padding: 6px 12px;
  32. }
  33. input {
  34. background-color: #FFF;
  35. background-image: none;
  36. border: 1px solid #ccc;
  37. border-radius: 1px;
  38. color: inherit;
  39. padding: 6px 12px;
  40. }
  41. #sqzx td {
  42. padding: 6px 0 5px 10px;
  43. }
  44. .lxr ul li {
  45. float: left;
  46. list-style: none;
  47. width: 30%;
  48. margin-bottom: 5px;
  49. padding-top: 10px;
  50. }
  51. .clearFix:after {
  52. content: "";
  53. display: block;
  54. clear: both;
  55. }
  56. .form-group {
  57. padding-left: 40px;
  58. margin-bottom: 0;
  59. }
  60. textarea {
  61. height: 70px;
  62. border: 1px solid #ccc;
  63. border-radius: 1px;
  64. width: 50%;
  65. resize: none;
  66. }
  67. .textarea_box {
  68. margin-top: 10px;
  69. }
  70. .box_content {
  71. border-bottom: 1px solid #ccc;
  72. }
  73. .tj_content {
  74. border: 1px solid #e6e6e6;
  75. border-radius: 5px;
  76. }
  77. .t-shade {
  78. position: fixed;
  79. top: 0;
  80. left: 0;
  81. width: 100%;
  82. background: rgba(0, 0, 0, 0.48);
  83. z-index: 10004;
  84. display: none;
  85. }
  86. .lyxz .shade_k {
  87. z-index: 10005;
  88. width: 40%;
  89. left: 30%;
  90. margin: 20% auto;
  91. position: absolute;
  92. background-color: #fff;
  93. box-shadow: 1px 1px 50px rgba(0, 0, 0, .3);
  94. border-radius: 5px;
  95. }
  96. .shade_title {
  97. padding: 0 80px 0 20px;
  98. height: 42px;
  99. line-height: 42px;
  100. border-bottom: 1px solid #eee;
  101. font-size: 16px;
  102. color: #FFFFFF;
  103. overflow: hidden;
  104. background-color: #00a1cb;
  105. border-radius: 2px 2px 0 0;
  106. position: relative;
  107. border-top-left-radius: 5px;
  108. border-top-right-radius: 5px;
  109. }
  110. .cx {
  111. display: block;
  112. }
  113. .setwin {
  114. position: absolute;
  115. right: 15px;
  116. top: 5px;
  117. font-size: 0;
  118. line-height: initial;
  119. }
  120. .setwin a {
  121. position: relative;
  122. width: 16px;
  123. height: 16px;
  124. font-size: 20px;
  125. color: #fff;
  126. }
  127. .xg i {
  128. font-size: 16px;
  129. }
  130. .hidens {
  131. display: none;
  132. }
  133. .Min-width{
  134. width: 150px;
  135. }
  136. .hidens {
  137. display: none;
  138. }
  139. .inpBox {
  140. border: 1px solid #a9a9a9;
  141. height: 27px;
  142. width: 220px;
  143. display: inline-block;
  144. position: relative;
  145. vertical-align: middle;
  146. }
  147. .addTree {
  148. background: #fff;
  149. position: absolute;
  150. width: 100%;
  151. border: 1px solid darkgrey;
  152. right: 0;
  153. top: 26px;
  154. display: none;
  155. z-index: 222;
  156. }
  157. .xl {
  158. display: inline-block;
  159. background: url(../../img/dropDown.png) no-repeat;
  160. height: 100%;
  161. background-position: center center;
  162. width: 20px;
  163. position: absolute;
  164. right: 0;
  165. top: 0px;
  166. /* background-color: #f7bc8b; */
  167. cursor: pointer;
  168. }
  169. .ztree li span {
  170. border: none;
  171. padding: 0;
  172. }
  173. .inps {
  174. width: 217px;
  175. height: 24px;
  176. outline: none;
  177. border: 0;
  178. border-image-width: 0;
  179. padding: 0;
  180. padding-left: 3px;
  181. }
  182. .xl {
  183. display: inline-block;
  184. background: url(../img/dropDown.png) no-repeat;
  185. height: 100%;
  186. background-position: center center;
  187. width: 20px;
  188. position: absolute;
  189. right: 0;
  190. top: 0px;
  191. /* background-color: #f7bc8b; */
  192. cursor: pointer;
  193. }
  194. .Cleans{
  195. display: inline-block;
  196. width: 20px;
  197. position: absolute;
  198. right: 21px;
  199. top: 5px;
  200. display: none;
  201. }
  202. </style>
  203. </head>
  204. <body class="gray-bg">
  205. <div class="wrapper wrapper-content animated fadeInRight">
  206. <div class="daoHang clearfix">
  207. <div class="dhLeft">
  208. <sapn>
  209. <i class="syIcon"></i>位置:
  210. <a href="javaScript:;" id="ReIndex">首页</a>&gt;
  211. <a href="javaScript:;">业务监督</a>&gt;
  212. <a class="nowPosition">坐席待处理</a>
  213. </sapn>
  214. </div>
  215. <div class="dhRight">
  216. <a href="" title="刷新"><i class="fa fa-refresh"></i></a>
  217. </div>
  218. </div>
  219. <div style="padding: 10px;" class="tj_content clearFix">
  220. <div style="padding: 10px;" class="tj_content clearFix">
  221. <div>
  222. <span>【搜索信息】</span>
  223. <div class="box_content">
  224. <table id="sqzx" style="width: 100%;" border="0" cellspacing="0" cellpadding="0">
  225. <tr>
  226. <th>诉求标题:</th>
  227. <td>
  228. <input type="text" placeholder="输入关键字" id="key" class="Min-width" />
  229. </td>
  230. <th>工单号:</th>
  231. <td>
  232. <input type="text" placeholder="输入工单号" id="wids" class="Min-width" />
  233. </td>
  234. <th>时间:</th>
  235. <td>
  236. <input type="text" id="starttime" class="laydate-icon Min-width" style="height: 32px;" />&nbsp;——&nbsp;<input type="text" id="endtime" class="laydate-icon Min-width" style="height: 32px;" />
  237. </td>
  238. <th>区域:</th>
  239. <td >
  240. <select name="" id="sourceAreas" class="select">
  241. </select>
  242. </td>
  243. </tr>
  244. <tr>
  245. <th>工单状态:</th>
  246. <td>
  247. <select name="" id="state" class="select">
  248. <option value=>请选择</option>
  249. <option value="0"selected="selected">新工单</option>
  250. <option value="10">待审核</option>
  251. <option value="6">已办理</option>
  252. </select>
  253. </td>
  254. <th>工单来源:</th>
  255. <td>
  256. <select class="select_" id="source">
  257. </select>
  258. </td>
  259. <th>主题词:</th>
  260. <td>
  261. <select id="keyid" name="" class="select"></select>
  262. </td>
  263. <th>类型:</th>
  264. <td>
  265. <select class="select_" id="type">
  266. </select>
  267. </td>
  268. </tr>
  269. <tr>
  270. <th>投诉电话:</th>
  271. <td>
  272. <input type="text" id="tel" class="Min-width" />
  273. </td>
  274. <th>投诉人:</th>
  275. <td>
  276. <input type="text" id="name" class="Min-width"/>
  277. </td>
  278. </tr>
  279. <tr>
  280. <th>坐席:</th>
  281. <td>
  282. <select id="ZX" name="select" class="selectpicker show-tick form-control" multiple data-live-search="true">
  283. <option value="">请选择坐席</option>
  284. </select>
  285. </td>
  286. <th>调度员:</th>
  287. <td>
  288. <select id="yardman" name="select" class="selectpicker show-tick form-control" multiple data-live-search="true">
  289. <option value="">请选择调度员</option>
  290. </select>
  291. </td>
  292. <th>主办单位:</th>
  293. <td>
  294. <div class="inpBox">
  295. <input type="text" class="inps" />
  296. <i class="Cleans fa fa-close"></i>
  297. <i class="xl xl_one"></i>
  298. <div class="addTree xlAdd">
  299. <ul id="addTreeDemo" class="ztree">
  300. </ul>
  301. </div>
  302. </div>
  303. </td>
  304. <th></th>
  305. <td style="text-align: center;">
  306. <botton class="btns Seach">搜索</botton>
  307. <!--<botton class="btns ">导出</botton>-->
  308. </td>
  309. </tr>
  310. </table>
  311. </div>
  312. </div>
  313. <div>
  314. <div style="width: 100%;padding: 10px;">
  315. <table id="orderlist" data-row-style="rowStyle" data-query-params="queryParams" data-pagination="true">
  316. <thead>
  317. <tr>
  318. <th data-checkbox="true"></th>
  319. <th data-field="F_WorkOrderId" data-align="center">工单单号</th>
  320. <th data-field="F_ComTitle" data-formatter="GetCont" data-align="center">诉求标题</th>
  321. <th data-field="DeptName" data-align="center">主办单位</th>
  322. <th data-field="OtherDeptName" data-align="center">协办单位</th>
  323. <th data-field="UserName" data-align="center">受理人</th>
  324. <th data-field="F_WorkState" data-align="center" data-formatter="States">办理状态</th>
  325. <th data-field="FilePath" data-formatter="setCode" data-align="center">录音</th>
  326. <th data-field="OverState" data-formatter="OverTime" data-align="center">时限</th>
  327. <th data-field="LimitTime" data-formatter="BanTime" data-align="center">办理时限</th>
  328. <th data-field="F_WorkOrderId" data-formatter="Dispose" data-align="center">操作</th>
  329. </tr>
  330. </thead>
  331. <tbody class="list"></tbody>
  332. </table>
  333. </div>
  334. </div>
  335. </div>
  336. </div>
  337. <!--下载框-->
  338. <div class="t-shade lyxz">
  339. <div class="shade_k">
  340. <div class="shade_title">
  341. <span>录音播放与下载<srong class="cknum"></srong></span>
  342. <span class="setwin gbly"><a>x</a></span>
  343. </div>
  344. <div class="shade_content">
  345. <div class="Ly_box audiojs">
  346. </div>
  347. </div>
  348. </div>
  349. </div>
  350. <input type="hidden" id="PID" />
  351. <input type="hidden" id="Dpment" />
  352. </div>
  353. <script src="../js/bootstrap-select.js"></script>
  354. <script src="../css/laydate/laydate.js"></script>
  355. <script src="../My97DatePicker/WdatePicker.js"></script>
  356. <script src="../js/zTree/jquery.ztree.core.js"></script>
  357. <script src="../js/search/screen.js"></script>
  358. <script>
  359. // return '<div class="imgs" >' +
  360. // '<a class="xg" title="查看" onclick="ckxq(' + val + ')"> <i class="fa fa-search"></i></a>' +
  361. // '<a class="xg" title="编辑" onclick="bj(' + val + ')"> <i class="fa fa-pencil-square-o"></i></a>' +
  362. // '<a class="xg" title="回访" onclick="back(' + val + ')"> <i class="fa fa-mail-reply"></i></a>' +
  363. // '<a class="xg" "title="强回"onclick="recycles(' + val + ')"> <i class="fa fa-exchange"></i></a>' +
  364. // '<a class="xg" title="结案" onclick="Lawsuit(' + val + ')"> <i class="fa fa-pie-chart"></i></a>' +
  365. // '<a class="xg" "title="交办"onclick="jb(' + val + ')"> <i class="fa fa-check-square-o"></i></a>' +
  366. // '<a class="xg" "title="回收"onclick="recycle(' + val + ')"> <i class="fa fa-retweet"></i></a>' +
  367. // '<a class="xg "title="督查" onclick="Supervision(' + val + ')"> <i class="fa fa-eye"></i></a>' +
  368. // '<a class="xg" "title="强制" onclick="StrongLawsuit(' + val + ')"> <i class="fa fa-check-circle"></i></a>' +
  369. // '<a class="xg" title="删除"onclick="move(' + val + ')"> <i class="fa fa-remove"></i></a>' +
  370. // '</div>';
  371. var wid = helper.request.queryString("states");
  372. if(wid){
  373. $("#state").val(wid);
  374. }
  375. $(document).ready(function() {
  376. load();
  377. LY($("#source"));
  378. LB($("#type"));
  379. ZT($("#keyid"));
  380. tree();
  381. helper.getDropList.getOrderAreas($('#sourceAreas'));
  382. laydate.skin('blue');
  383. laydate({
  384. elem: '#starttime',
  385. event: 'focus'
  386. });
  387. laydate({
  388. elem: '#endtime',
  389. event: 'focus'
  390. });
  391. ///搜素
  392. $(".Seach").click(function() {
  393. load();
  394. })
  395. $('.inps').focus(function() {
  396. $('.xlAdd').css('display', 'block')
  397. })
  398. $('.xl').click(function() {
  399. if($('.xlAdd').css('display') == 'block') {
  400. $('.xlAdd').css('display', 'none')
  401. } else {
  402. $('.xlAdd').css('display', 'block')
  403. }
  404. })
  405. $('.addTree').mouseleave(function() {
  406. $(this).css('display', 'none')
  407. })
  408. $(".Cleans ").click(function(){
  409. $('.inps').val("");
  410. $("#PID").val("");
  411. $("#Dpment").val("");
  412. })
  413. });
  414. //关闭录音弹出
  415. $(".gbly").click(function() {
  416. $(".lyxz").removeClass("cx");
  417. $('audio')[0].pause();
  418. });
  419. $("#orderlist").on("click-row.bs.table", function(e, row, ele) {
  420. $('.success').removeClass('success'); //去除之前选中的行的,选中样式
  421. $(ele).addClass('success'); //添加当前选中的 success样式用于区别
  422. });
  423. //获取查询信息
  424. function load() {
  425. //坐席
  426. var usercodeID="";
  427. var usercode_=$("#ZX").val(); //坐席
  428. if (usercode_!=null) {
  429. $(usercode_).each(function (i, n) {
  430. var obj1='';
  431. obj1= n+",";
  432. usercodeID +=obj1;
  433. })
  434. }else{
  435. usercodeID=""
  436. }
  437. // 调度员
  438. var ddusercodeID="";
  439. var ddusercode_=$("#yardman").val(); //坐席
  440. if (ddusercode_!=null) {
  441. $(ddusercode_).each(function (i, n) {
  442. var obj2='';
  443. obj2= n+",";
  444. ddusercodeID +=obj2;
  445. })
  446. }else{
  447. ddusercodeID=""
  448. }
  449. //先销毁表格
  450. $('#orderlist').bootstrapTable('destroy');
  451. //初始化表格,动态从服务器加载数据
  452. $("#orderlist").bootstrapTable({
  453. method: "get", //使用get请求到服务器获取数据
  454. url: huayi.config.callcenter_url + "WorkOrder/GetZXDealList", //获取数据的Servlet地址
  455. contentType: "application/x-www-form-urlencoded",
  456. striped: true, //表格显示条纹
  457. pagination: true, //启动分页
  458. pageSize: 10, //每页显示的记录数
  459. pageNumber: 1, //当前第几页
  460. pageList: [10, 20, 50, 100], //记录数可选列表
  461. search: false, //是否启用查询
  462. showColumns: false, //显示下拉框勾选要显示的列
  463. showRefresh: false, //显示刷新按钮
  464. sidePagination: "server", //表示服务端请求
  465. //设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
  466. //设置为limit可以获取limit, offset, search, sort, order
  467. queryParamsType: "undefined",
  468. queryParams: function queryParams(params) { //设置查询参数
  469. var param = {
  470. page: params.pageNumber,
  471. pagesize: params.pageSize,
  472. workid: $("#wids").val(),
  473. state: $("#state").val(), //=工单状态
  474. type: $("#type").val(), //=工单类型
  475. bigtype: $("#bigtype").val(), //=大类别
  476. smalltype: $("#smalltype").val(), //=小类别
  477. key: $("#key").val(), //=关键字
  478. tel: $("#tel").val(), //=客户电话
  479. name: $("#name").val(), //=客户名称
  480. usercode: usercodeID, //=坐席工号
  481. ddusercode: ddusercodeID,
  482. keyid: $("#keyid").val(), //=关键词id
  483. source: $("#source").val(), //=来源&
  484. starttime: $("#starttime").val(), //=开始时间
  485. endtime: $("#endtime").val(), //=结束时间
  486. deptid:$("#PID").val(),
  487. type:$("#type").val(),
  488. tab: 0,//待处理
  489. sourcearea:$('#sourceAreas').val(),//区域
  490. token: $.cookie("token")
  491. };
  492. return param;
  493. },
  494. onLoadSuccess: function(data) { //加载成功时执行
  495. // layer.msg("加载成功");
  496. //console.log(data);
  497. },
  498. onLoadError: function() { //加载失败时执行
  499. //layer.msg("加载数据失败", { time: 1500, icon: 2 });
  500. }
  501. });
  502. }
  503. //状态
  504. function States(val, row) {
  505. var html = '';
  506. switch (val + '') {
  507. case '0':
  508. html = '新工单';
  509. if (row.F_IsReturn == 1) {
  510. html = '新工单(回退)';
  511. }
  512. break;
  513. case '1':
  514. html = '待交办';
  515. break;
  516. case '2':
  517. html = '待查收';
  518. break;
  519. case '3':
  520. html = '退回审核中';
  521. break;
  522. case '4':
  523. html = '办理中';
  524. break;
  525. case '5':
  526. html = '延时审核';
  527. break;
  528. case '6':
  529. html = '已办理';
  530. break;
  531. case '7':
  532. html = '已回访';
  533. break;
  534. case '8':
  535. html = '重办中';
  536. break;
  537. case '9':
  538. html = '已结案';
  539. break;
  540. case '10':
  541. html = '待审核';
  542. break;
  543. case '11':
  544. html = '重办待交办';
  545. break;
  546. case '12':
  547. html = '待审核';
  548. break;
  549. case '13':
  550. html = '待督办';
  551. break;
  552. }
  553. return html;
  554. }
  555. //时限
  556. function OverTime(val,row){
  557. if(val==1){
  558. return '<div class="" style="cursor: pointer;">' +
  559. '<span class="Greens">'+row.GapTime+'</span>'+
  560. '</div>';
  561. }else if(val==2){
  562. return '<div class="" style="cursor: pointer;">' +
  563. '<span class="Yellows">'+row.GapTime+'</span>'+
  564. '</div>';
  565. }else if(val==3){
  566. return '<div class="" style="cursor: pointer;">' +
  567. '<span class="Reds">'+row.GapTime+'</span>'+
  568. '</div>';
  569. }
  570. }
  571. //办理时限
  572. function BanTime(val){
  573. if(val){
  574. var time=val.substring(0,val.indexOf(' '));
  575. return '<div class="" style="cursor: pointer;">' +
  576. '<span>'+time+'</span>'+
  577. '</div>';
  578. }
  579. }
  580. //音频
  581. function setCode(val) {
  582. if(val) {
  583. return '<div class="imgs" style="cursor: pointer;">' +
  584. '<img src="../img/vice.png" alt="" onclick= "helper.luyin.view(this)" item="' + val + '" />' +
  585. '</div>';
  586. } else {
  587. return '';
  588. }
  589. }
  590. function GetCont(val) {
  591. if(val) {
  592. var str = '<div '
  593. if(val.length > 10) {
  594. str = str + ' title="' + val + '" ';
  595. val = val.substr(0, 10) + "...";
  596. }
  597. return str + '>' + val + '</div>';
  598. } else {
  599. return '';
  600. }
  601. }
  602. //操作
  603. function Dispose(val, row) {
  604. var Rows = row.Buttons;
  605. var html = '';
  606. for(var i = 0; i < Rows.length; i++) {
  607. var html1 = huayi.config.arr[Rows[i].key * 1 - 1];
  608. if(html1) {
  609. html1 = html1.replace("data", val);
  610. }
  611. html += html1;
  612. }
  613. return html;
  614. }
  615. //查看详情
  616. function ckxq(str) {
  617. layer.open({
  618. type: 2,
  619. content: "../CommonHtml/WorkDatil.html?wid=" + str, //iframe的url,no代表不显示滚动条
  620. title: '工单详情',
  621. area: ['85%', '80%'], //宽高
  622. });
  623. }
  624. //编辑
  625. function bj(str) {
  626. layer.open({
  627. type: 2,
  628. content: "../CommonHtml/AddAppeal.html?wid=" + str, //iframe的url,no代表不显示滚动条
  629. title: '编辑工单',
  630. area: ['96%', '80%'], //宽高
  631. });
  632. }
  633. //删除
  634. function move(str) {
  635. layer.confirm('确定删除工单?', {
  636. btn: ['是', '否'] //按钮
  637. }, function() {
  638. $.post(huayi.config.callcenter_url + "WorkOrder/DelWorkOrder", {
  639. ids: str,
  640. token: $.cookie("token")
  641. }, function(result) {
  642. result = JSON.parse(result);
  643. if(result.state.toLowerCase() == "success") {
  644. layer.msg("删除成功");
  645. load();
  646. }
  647. })
  648. });
  649. }
  650. //提交
  651. function tj(str) {
  652. layer.confirm('确定要提交工单么?', {
  653. btn: ['确定', '取消'] //按钮
  654. }, function() {
  655. //请求后台数据
  656. /*发送请求*/
  657. $.post(huayi.config.callcenter_url + "WorkOrder/SubmitWorkOrder", {
  658. ids: str,
  659. token: $.cookie("token")
  660. }, function(result) {
  661. result = JSON.parse(result);
  662. if(result.state.toLowerCase() == "success") {
  663. layer.msg("提交成功");
  664. load();
  665. }
  666. })
  667. });
  668. }
  669. //交办
  670. function jb(str) {
  671. layer.open({
  672. type: 2,
  673. content: "../CommonHtml/JiaoBan.html?wid=" + str, //iframe的url,no代表不显示滚动条
  674. title: '工单交办',
  675. area: ['87%', '80%'], //宽高
  676. });
  677. }
  678. //领导批示
  679. function lader(str) {
  680. layer.open({
  681. type: 2,
  682. content: "../CommonHtml/Leader.html?wid=" + str, //iframe的url,no代表不显示滚动条
  683. title: '领导批示',
  684. area: ['45%', '40%'], //宽高
  685. });
  686. }
  687. //市长批示
  688. function city(str) {
  689. layer.open({
  690. type: 2,
  691. content: "../CommonHtml/shizhang.html?wid=" + str, //iframe的url,no代表不显示滚动条
  692. title: '领导批示',
  693. area: ['45%', '40%'], //宽高
  694. });
  695. }
  696. //办理
  697. function bl(str) {
  698. layer.open({
  699. type: 2,
  700. content: "../CommonHtml/banli.html?wid=" + str, //iframe的url,no代表不显示滚动条
  701. title: '办理工单',
  702. area: ['45%', '40%'], //宽高
  703. });
  704. }
  705. //督办
  706. function Supervision(str) {
  707. layer.open({
  708. type: 2,
  709. content: "../CommonHtml/Supervision_.html?wid=" + str + '&type=1', //iframe的url,no代表不显示滚动条
  710. title: '督办',
  711. area: ['35%', '30%'], //宽高
  712. });
  713. }
  714. //督查
  715. function Supervision_(str) {
  716. layer.open({
  717. type: 2,
  718. content: "../CommonHtml/Supervision_.html?wid=" + str + '&type=2', //iframe的url,no代表不显示滚动条
  719. title: '监察',
  720. area: ['35%', '30%'], //宽高
  721. });
  722. }
  723. //强制结案
  724. function StrongLawsuit(str) {
  725. layer.open({
  726. type: 2,
  727. content: "../CommonHtml/StrongLawsuit.html?wid=" + str, //iframe的url,no代表不显示滚动条
  728. title: '强制结案',
  729. area: ['45%', '52%'], //宽高
  730. });
  731. }
  732. //回退BackDtail
  733. function BackDtail(str) {
  734. layer.open({
  735. type: 2,
  736. content: "../CommonHtml/BackDatil.html?wid=" + str, //iframe的url,no代表不显示滚动条
  737. title: '工单回退',
  738. area: ['45%', '40%'], //宽高
  739. });
  740. }
  741. //查收
  742. function cs(str) {
  743. layer.confirm('确定要查收?', {
  744. btn: ['是', '否'] //按钮
  745. }, function() {
  746. $.post(huayi.config.callcenter_url + "WorkOrder/ReceiveWorkOrder", {
  747. workorderid: str,
  748. token: $.cookie("token")
  749. }, function(result) {
  750. result = JSON.parse(result);
  751. if(result.state.toLowerCase() == "success") {
  752. layer.msg("查收成功");
  753. load();
  754. }
  755. })
  756. });
  757. }
  758. //收回
  759. function sh(str) {
  760. layer.confirm('确定要回收?', {
  761. btn: ['是', '否'] //按钮
  762. }, function() {
  763. $.post(huayi.config.callcenter_url + "WorkOrder/TakeBackWorkOrder", {
  764. workorderid: str,
  765. token: $.cookie("token")
  766. }, function(result) {
  767. result = JSON.parse(result);
  768. if(result.state.toLowerCase() == "success") {
  769. layer.msg("回收");
  770. load();
  771. }
  772. })
  773. });
  774. }
  775. //强制回收
  776. function recycles() {
  777. layer.confirm('确定要强制退回吗?', {
  778. btn: ['是', '否'] //按钮
  779. });
  780. }
  781. //退回申请
  782. function th(str) {
  783. layer.open({
  784. type: 2,
  785. content: "../CommonHtml/tuihuisq.html?wid=" + str, //iframe的url,no代表不显示滚动条
  786. title: '申请退回工单',
  787. area: ['35%', '30%'], //宽高
  788. });
  789. }
  790. //审核退回申请
  791. function shth(str) {
  792. layer.open({
  793. type: 2,
  794. content: "../CommonHtml/shth.html?wid=" + str, //iframe的url,no代表不显示滚动条
  795. title: '审核退回申请',
  796. area: ['35%', '30%'], //宽高
  797. });
  798. }
  799. //办理
  800. // function th(str) {
  801. // layer.open({
  802. // type: 2,
  803. // content: "../CommonHtml/tuihuisq.html?wid=" + str, //iframe的url,no代表不显示滚动条
  804. // title: '办理工单',
  805. // area: ['35%', '30%'], //宽高
  806. // });
  807. // }
  808. //申请延时
  809. function ys(str) {
  810. layer.open({
  811. type: 2,
  812. content: "../CommonHtml/Timesq.html?wid=" + str, //iframe的url,no代表不显示滚动条
  813. title: '申请延时',
  814. area: ['45%', '40%'], //宽高
  815. });
  816. }
  817. //审核申请延时
  818. function shys(str) {
  819. layer.open({
  820. type: 2,
  821. content: "../CommonHtml/shtime.html?wid=" + str, //iframe的url,no代表不显示滚动条
  822. title: '审核延时申请',
  823. area: ['45%', '40%'], //宽高
  824. });
  825. }
  826. //诉求回访
  827. function hf(str) {
  828. layer.open({
  829. type: 2,
  830. content: "../CommonHtml/Back.html?wid=" + str, //iframe的url,no代表不显示滚动条
  831. title: '工单回访',
  832. area: ['45%', '40%'], //宽高
  833. });
  834. }
  835. //重办工单
  836. function cb(str) {
  837. layer.open({
  838. type: 2,
  839. content: "../CommonHtml/Cb.html?wid=" + str, //iframe的url,no代表不显示滚动条
  840. title: '重办工单',
  841. area: ['45%', '40%'], //宽高
  842. });
  843. }
  844. //结案
  845. function Lawsuit(str) {
  846. layer.open({
  847. type: 2,
  848. content: "../CommonHtml/lawsuits.html?wid=" + str, //iframe的url,no代表不显示滚动条
  849. title: '诉求单结案',
  850. area: ['45%', '40%'], //宽高
  851. });
  852. }
  853. $('.Appeal').click(function() {
  854. layer.open({
  855. type: 2,
  856. content: "../CommonHtml/AddAppeal.html?wid=", //iframe的url,no代表不显示滚动条
  857. title: '新增诉求',
  858. area: ['85%', '80%'], //宽高
  859. });
  860. })
  861. //上传文件
  862. function upload() {
  863. if(document.getElementById("upFile").files.length > 0) {
  864. var formData = new FormData();
  865. formData.append("upFile", document.getElementById("upFile").files[0]);
  866. formData.append("token", $.cookie("token"));
  867. $.ajax({
  868. url: huayi.config.callcenter_url + "/WorkOrder/UploadFile",
  869. type: "POST",
  870. data: formData,
  871. /**
  872. *必须false才会自动加上正确的Content-Type
  873. */
  874. contentType: false,
  875. /**
  876. * 必须false才会避开jQuery对 formdata 的默认处理
  877. * XMLHttpRequest会对 formdata 进行正确的处理
  878. */
  879. processData: false,
  880. success: function(result) {
  881. document.getElementById("upFile").outerHTML = document.getElementById("upFile").outerHTML;
  882. $("#upFile").change(function() {
  883. upload();
  884. });
  885. var r = $.parseJSON(result);
  886. if(r.state.toLowerCase() == "success") {
  887. $(".fjnr").text(r.data);
  888. $("#scfj").show();
  889. }
  890. }
  891. });
  892. } else {
  893. layer.confirm('请上传文件!', {
  894. btn: ['确定']
  895. });
  896. }
  897. }
  898. //来源
  899. function LY(obj) {
  900. obj.empty();
  901. obj.append('<option selected="selected" value="">请选择</option>');
  902. $.getJSON(huayi.config.callcenter_url + "Dictionary/GetDicValueListById", {
  903. "token": $.cookie("token"),
  904. id: 1
  905. }, function(data) {
  906. if(data.state.toLowerCase() == "success") {
  907. var content = data.data;
  908. $(content).each(function(i, n) {
  909. $("<option value='" + n.F_ValueId + "'>" + n.F_Value + "</option>").appendTo(obj);
  910. })
  911. }
  912. })
  913. }
  914. //类别
  915. function LB(obj) {
  916. obj.empty();
  917. obj.append('<option selected="selected" value="">请选择</option>');
  918. $.getJSON(huayi.config.callcenter_url + "Dictionary/GetDicValueListById", {
  919. "token": $.cookie("token"),
  920. id: 2
  921. }, function(data) {
  922. if(data.state.toLowerCase() == "success") {
  923. var content = data.data;
  924. $(content).each(function(i, n) {
  925. $("<option value='" + n.F_ValueId + "'>" + n.F_Value + "</option>").appendTo(obj);
  926. })
  927. }
  928. })
  929. }
  930. // 主题
  931. function ZT(obj) {
  932. obj.empty();
  933. obj.append('<option selected="selected" value="">请选择</option>');
  934. $.getJSON(huayi.config.callcenter_url + "Dictionary/GetDicValueListById", {
  935. "token": $.cookie("token"),
  936. id: 3
  937. }, function(data) {
  938. if(data.state.toLowerCase() == "success") {
  939. var content = data.data;
  940. $(content).each(function(i, n) {
  941. $("<option value='" + n.F_ValueId + "'>" + n.F_Value + "</option>").appendTo(obj);
  942. })
  943. }
  944. })
  945. }
  946. function tree() {
  947. $.get(huayi.config.callcenter_url + 'Department/GetDeptList', {
  948. "token": $.cookie("token"),
  949. // "pid": pid
  950. }, function(result) {
  951. result = $.parseJSON(result);
  952. $.fn.zTree.init($("#addTreeDemo"), setting1, result.data); //实例化树形图
  953. });
  954. }
  955. var setting1 = {
  956. data: {
  957. key: {
  958. name: "F_DeptName"
  959. },
  960. simpleData: {
  961. enable: true,
  962. idKey: "F_DeptId",
  963. pIdKey: "F_PartentId",
  964. rootPId: 0
  965. }
  966. },
  967. callback: {
  968. onClick: zTreeOnClick
  969. }
  970. };
  971. function zTreeOnClick(event, treeId, treeNode) {
  972. if(treeNode.level >= 2) {
  973. $('.inps').val(treeNode.F_DeptName);
  974. $("#PID").val(treeNode.F_DeptId);
  975. $("#Dpment").val(treeNode.F_DeptName);
  976. $(".Cleans").show();
  977. }
  978. };
  979. </script>
  980. </body>
  981. </html>