12345市长热线标准版-前端

Lawsuit.html 25KB

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