Няма описание

LeaderYZBMarketing.html 34KB

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