Sin descripción

toSupervListProvincialPlatform.html 34KB

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