Ei kuvausta

toSupervList.html 34KB

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