Bez popisu

WorkDC.html 40KB

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