暂无描述

superviseComprehensiveInquiries.html 35KB

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