ZZDianXin_UI - 郑州电信 演示

WorkOrderDispose.html 24KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>待处理工单</title>
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <script src="../Script/Common/huayi.load.js"></script>
  8. <script src="../Script/Common/huayi.config.js"></script>
  9. <link rel="stylesheet" href="../js/zTree/zTreeStyle.css" />
  10. <link href="../css/WorkOrder/Search.css" rel="stylesheet">
  11. <link href="../js/bootstrap-select/css/bootstrap-select.css" rel="stylesheet" />
  12. <link rel="stylesheet" href="../js/comboSelect/combo.select.css" />
  13. <link href="../css/init.css" rel="stylesheet" />
  14. <style>
  15. .time-box {
  16. display: inline-block;
  17. position: relative;
  18. }
  19. i.tub {
  20. position: absolute;
  21. right: 8px;
  22. top: 8px;
  23. font-size: 18px;
  24. color: #1ab394;
  25. }
  26. .search_time {
  27. width: 228px!important;
  28. }
  29. .bootstrap-select>.dropdown-toggle.bs-placeholder {
  30. background-color: #ffffff!important;
  31. border-color: #e5e6e7!important;
  32. }
  33. .filter-option {
  34. color: #676b6d;
  35. }
  36. .bootstrap-select>.dropdown-toggle.btn-default {
  37. background-color: #ffffff!important;
  38. border-color: #e5e6e7!important;
  39. color: #555;
  40. }
  41. #typeclass {
  42. background: #fff;
  43. }
  44. .treeList {
  45. top: 34px!important;
  46. border: 1px solid #e5e6e7!important;
  47. border-top: 0;
  48. height: auto!important;
  49. }
  50. #TreeDemo li {
  51. float: initial;
  52. }
  53. #ce,
  54. #ces {
  55. display: none;
  56. }
  57. .E73 {
  58. background: #87eebf;
  59. color: #000;
  60. width: 100px;
  61. }
  62. .E72 {
  63. width: 100px;
  64. }
  65. ._table1>thead>tr>th {
  66. text-align: right;
  67. padding: 4px !important;
  68. width: 25%;
  69. }
  70. ._table1>thead>tr>td {
  71. padding: 4px !important;
  72. width: 25%;
  73. }
  74. .imgs a{
  75. padding-right: 5px;
  76. }
  77. .inps2,.inps3{
  78. display: none;
  79. }
  80. .W50 .th-inner {
  81. width:50px !important;
  82. }
  83. .W60 .th-inner {
  84. width:60px !important;
  85. }
  86. .W60margin .th-inner {
  87. width:60px !important;
  88. margin-right: 220px !important;
  89. }
  90. .W60margin{
  91. width:60px !important;
  92. text-align: left !important;
  93. }
  94. .W80 .th-inner {
  95. width:80px !important;
  96. }
  97. .W90 .th-inner {
  98. width:90px !important;
  99. }
  100. .W100 .th-inner {
  101. width:100px !important;
  102. }
  103. .W120 .th-inner {
  104. width:120px !important;
  105. }
  106. .W150 .th-inner {
  107. width:150px !important;
  108. }
  109. .W160 .th-inner {
  110. width:200px !important;
  111. }
  112. .create_time .th-inner {
  113. width:200px !important;
  114. /*padding-left: 150px !important;*/
  115. }
  116. .create_time{
  117. width: 200px !important;
  118. padding-left: 149px !important;
  119. }
  120. .W170 .th-inner {
  121. width:170px !important;
  122. }
  123. .W220 .th-inner {
  124. width:220px !important;
  125. position: absolute;
  126. right: 0;
  127. top: 0;
  128. border-left: 1px solid #DDDDDD ;
  129. background: #F3F3F4;
  130. height: 40px;
  131. border-bottom: 1px solid #DDDDDD;
  132. }
  133. .W220{
  134. width:220px !important;
  135. position: absolute;
  136. right: 0;
  137. background: #F3F3F4;
  138. border-bottom: 1px solid #DDDDDD;
  139. }
  140. .ordernumber{
  141. width: 150px !important;
  142. position: absolute;
  143. left: 0;
  144. background: #F3F3F4;
  145. border-right: 1px solid #DDDDDD;
  146. }
  147. .ordernumber .th-inner{
  148. width: 150px !important;
  149. position: absolute;
  150. left: 0;
  151. top: 0;
  152. height: 40px;
  153. background: #F3F3F4;
  154. border-right: 1px solid #DDDDDD;
  155. border-bottom: 1px solid #DDDDDD;
  156. }
  157. </style>
  158. </head>
  159. <body class="gray-bg">
  160. <div class="daoHang clearfix">
  161. <div class="dhLeft">
  162. <sapn>
  163. <i class="syIcon"></i>位置:
  164. <a href="javaScript:;" id="ReIndex">首页</a>&gt;
  165. <a href="javaScript:;">工单管理</a>&gt;
  166. <a href="" class="nowPosition">待处理工单</a>
  167. </sapn>
  168. </div>
  169. <div class="dhRight">
  170. <a href="#" title="刷新"><i class="fa fa-refresh"></i></a>
  171. </div>
  172. </div>
  173. <div class="wrapper wrapper-content animated fadeInRight">
  174. <div class="toolBox">
  175. <div class="th-bar clearfix">
  176. <div class="pull-left">
  177. <div class="form-inline">
  178. <!--<div class="form-group">
  179. <select class="form-control selectpicker" id="orderSource" data-live-search="true">
  180. <option value="">请选择工单来源</option>
  181. </select>
  182. </div>-->
  183. <div class="form-group">
  184. <select class="form-control selectpicker" id="orderType" data-live-search="true">
  185. <option value="">请选择工单类型</option>
  186. </select>
  187. </div>
  188. <!--<div class="form-group">
  189. <select class="form-control selectpicker" id="productTypeFilt" data-live-search="true">
  190. <option value="">请选择产品类别</option>
  191. </select>
  192. </div>-->
  193. <div class="time-box form-group">
  194. <i class="tub fa fa-caret-down down" style="color: #676b6d;"></i>
  195. <input class="form-control" type="text" id="typeclass" placeholder="请选择创建人" readonly="readonly">
  196. <input type="text" class="inps2">
  197. <input type="text" class="inps3">
  198. <input type="hidden" id="typeclassId" />
  199. <div class="addTree treeList">
  200. <p class="plasechoce">请选择</p>
  201. <ul id="TreeDemo" class="ztree">
  202. </ul>
  203. </div>
  204. </div>
  205. <div class="time-box form-group">
  206. <i class="tub fa fa-calendar"></i>
  207. <input class="form-control search_time" type="text" id="greetingTimes" placeholder="请选择时间">
  208. </div>
  209. <div class="time-box form-group">
  210. <input class="form-control" type="text" id="cityName" placeholder="请输入营业厅名称">
  211. </div>
  212. <div class="time-box form-group">
  213. <input class="form-control" type="text" id="keyWord" placeholder="请输入关键字">
  214. </div>
  215. <div class="time-box form-group">
  216. <input class="form-control" type="text" id="orderNum" placeholder="请输入工单号">
  217. </div>
  218. </div>
  219. <!--<span style="display:none">登录时间:<input type="text" class="laydate-icon loginTime" id="startTime"/></span>-->
  220. </div>
  221. <div class="pull-right">
  222. <button class="btns ss">搜索</button>
  223. <!--<button class="btns gjss">高级搜索</button>-->
  224. <a class="btns" onclick="dcexcel(this)">导出</a>
  225. </div>
  226. </div>
  227. </div>
  228. <!--<div style="width: 100%;padding: 10px;" id="ce" class="customerService">-->
  229. <div style="width: 100%;padding: 10px;" id="ce">
  230. <table id="workorderlist" class="market" data-row-style="rowStyle" data-query-params="queryParams" data-pagination="true">
  231. <thead>
  232. <tr>
  233. <th data-field="F_WorkOrderId" data-formatter="View" data-align="center">工单编号</th>
  234. <th data-field="F_CreateTime" data-align="center">创建时间</th>
  235. <th data-field="F_CreateUser" data-align="center">创建人</th>
  236. <th data-field="F_State" data-formatter="GetStateName" data-align="center">工单状态</th>
  237. <th data-field="F_Content" data-align="center" data-formatter="Detail" style="width:500px;">描述内容</th>
  238. <th data-field="F_CusName" data-formatter="characterFive" data-align="center" data-class="E73">客户姓名</th>
  239. <th data-field="F_CusPhone" data-align="center">客户电话</th>
  240. <th data-field="F_Typeof" data-align="center">工单类型</th>
  241. <th data-field="F_Definition" data-align="center">营业厅名称</th>
  242. <th data-field="F_Dealing" data-align="center">处理人</th>
  243. <th data-field="" data-align="center">录音</th>
  244. <th data-field="F_WorkOrderId" data-formatter="Appoint" data-align="center">操作</th>
  245. </tr>
  246. </thead>
  247. </table>
  248. </div>
  249. <div style="width: 100%;padding: 10px;" id="ces">
  250. <table id="workorderlist_" class="market" data-row-style="rowStyle" data-query-params="queryParams" data-pagination="true">
  251. <thead>
  252. <tr>
  253. <th data-field="F_WorkOrderId" data-formatter="View" data-align="center">工单编号</th>
  254. <th data-field="F_CreateTime" data-align="center">创建时间</th>
  255. <th data-field="F_CreateUser" data-align="center">创建人</th>
  256. <th data-field="F_State" data-formatter="GetStateName" data-align="center">工单状态</th>
  257. <th data-field="F_Content" data-align="center" data-formatter="Detail" style="width:500px;">描述内容</th>
  258. <th data-field="F_CusName" data-formatter="characterFive" data-align="center" data-class="E73">客户姓名</th>
  259. <th data-field="F_CusPhone" data-align="center">客户电话</th>
  260. <th data-field="F_Typeof" data-align="center">工单类型</th>
  261. <!--<th data-field="F_Definition" data-align="center">营业厅名称</th>-->
  262. <!--<th data-field="F_Dealing" data-align="center">处理人</th>-->
  263. <th data-field="" data-align="center">录音</th>
  264. <th data-field="F_WorkOrderId" data-formatter="Dispose" data-align="center">操作</th>
  265. </tr>
  266. </thead>
  267. </table>
  268. </div>
  269. <!--查看详情-->
  270. <div class="ckxq Hidens">
  271. <ul class="clearfix ckxq_ul">
  272. <li class="Active">工单详情</li>
  273. <li>跟进记录</li>
  274. <!--<li>催办记录</li>
  275. <li>评论记录</li>-->
  276. <span class="Closed">×</span>
  277. </ul>
  278. <div class="gdxq">
  279. <div class="">
  280. <table id="gdxq_table" border="0" class="table table-bordered table-hover " style="width: 100%;">
  281. <tbody class="tbodys">
  282. <tr>
  283. <th>工单编号:</th>
  284. <td>
  285. <span id="xq_gdbh"></span>
  286. </td>
  287. <th>工单类型:</th>
  288. <td>
  289. <span id="xq_gdlx"></span>
  290. </td>
  291. <th>定责:</th>
  292. <td>
  293. <span id="complaintType1"></span>
  294. </td>
  295. </tr>
  296. <tr>
  297. <th>创建时间:</th>
  298. <td>
  299. <span id="xq_cjsj"></span>
  300. </td>
  301. <th>工单状态:</th>
  302. <td>
  303. <span id="xq_gdzt"></span>
  304. </td>
  305. <th>客户姓名:</th>
  306. <td>
  307. <span id="xq_khxm"></span>
  308. </td>
  309. </tr>
  310. <tr class="up_floor">
  311. <th>派单类型:</th>
  312. <td>
  313. <span id="complaintType2"></span>
  314. </td>
  315. <th>处理人姓名:</th>
  316. <td>
  317. <span id="dealing"></span>
  318. </td>
  319. <th>处理人电话:</th>
  320. <td>
  321. <span id="dealingtel"></span>
  322. </td>
  323. </tr>
  324. <tr>
  325. <th>客户电话:</th>
  326. <td>
  327. <span id="xq_khdh"></span>
  328. </td>
  329. <th class="up_floor">营业厅名称:</th>
  330. <td class="up_floor">
  331. <span id="definition"></span>
  332. </td>
  333. <!--<th>购买日期:</th>
  334. <td>
  335. <span id="buyDate"></span>
  336. </td>
  337. <th>购买地址:</th>
  338. <td>
  339. <span id="buyAddress"></span>
  340. </td>-->
  341. </tr>
  342. <tr>
  343. <th>描述内容:</th>
  344. <td colspan="5" id="conTent">
  345. </td>
  346. </tr>
  347. <tr>
  348. <th>回复内容:</th>
  349. <td colspan="5" id="replycontent">
  350. </td>
  351. </tr>
  352. <tr>
  353. <th>备注:</th>
  354. <td colspan="5" id="remark">
  355. </td>
  356. </tr>
  357. </tbody>
  358. </table>
  359. </div>
  360. </div>
  361. <div class="gdxq" style="display:none;">
  362. </div>
  363. </div>
  364. </div>
  365. <div class="t-shade">
  366. <!--处理工单-->
  367. <div class="shade_k clgd ">
  368. <div class="shade_title">
  369. <span>处理工单<srong class="cknum"></srong></span>
  370. <span class="setwin"><a>x</a></span>
  371. </div>
  372. <div class="shade_content">
  373. <div class="dgxx_table size-13">
  374. <table class="_table1 table table-bordered" border="0" cellspacing="0" cellpadding="0" style="width: 100%;">
  375. <thead>
  376. <tr>
  377. <th>工单编号:</th>
  378. <td>
  379. <span id="cl_gdbh"></span>
  380. </td>
  381. <th>工单类型:</th>
  382. <td>
  383. <span id="cl_gdlx"></span>
  384. </td>
  385. </tr>
  386. <tr>
  387. <th>客户姓名:</th>
  388. <td>
  389. <span id="cl_khxm"></span>
  390. </td>
  391. <th>客户电话:</th>
  392. <td>
  393. <span id="cl_khdh"></span>
  394. </td>
  395. </tr>
  396. </thead>
  397. <tr class="ns-2">
  398. <th>处理费用:</th>
  399. <td colspan="3">
  400. <div>&nbsp;
  401. <label style="font-weight: normal;">
  402. <input type="number" style="width: 60px; padding-left: 5px;" id="dealCost" />
  403. &nbsp;&nbsp;元
  404. </label>
  405. </div>
  406. </td>
  407. </tr>
  408. <tr>
  409. <th>处理状态:</th>
  410. <td colspan="3">
  411. <div class="disposeST">
  412. </div>
  413. </td>
  414. </tr>
  415. <tr class="ns-2">
  416. <th>响应状态:</th>
  417. <td colspan="3">
  418. <div class="responseST">
  419. </div>
  420. </td>
  421. </tr>
  422. <tr>
  423. <th>处理结果:</th>
  424. <td colspan="5">
  425. <div>
  426. <textarea id="dealCont" name="" rows="3" style="width:100%;"></textarea>
  427. </div>
  428. </td>
  429. </tr>
  430. <tr>
  431. <th>处理进展详述:</th>
  432. <td colspan="5">
  433. <div>
  434. <textarea id="cont" name="" rows="3" style="width:100%;"></textarea>
  435. </div>
  436. </td>
  437. </tr>
  438. </table>
  439. </div>
  440. <div class="clearfix wh_btn">
  441. <input type="button" value="确定" class="btn-info" id="clgd" />
  442. </div>
  443. </div>
  444. </div>
  445. </div>
  446. <script src="../js/zTree/jquery.ztree.core.js"></script>
  447. <script src="../js/laydate/laydate.js"></script>
  448. <script src="../js/bootstrap-select/js/bootstrap-select.js"></script>
  449. <script src="../js/comboSelect/jquery.combo.select.js"></script>
  450. <script src="../js/kindeditor/kindeditor.js"></script>
  451. <script src="../js/kindeditor/lang/zh_CN.js"></script>
  452. <script src="../js/WorkOrder/WorkOrder.js"></script>
  453. <script>
  454. var selid;
  455. var zpid;
  456. var stype = 1;
  457. $(document).ready(function() {
  458. laydate.render({
  459. elem: '#greetingTimes',
  460. range: '~',
  461. theme: '#1ab394',
  462. calendar: 'true'
  463. //type: 'datetime',
  464. //max : 31,
  465. //min: 0,
  466. });
  467. // alert(ns)
  468. //处理工单
  469. hideDiv();
  470. function hideDiv(){
  471. if(ns==2){
  472. $(".ns-2").remove();
  473. }
  474. }
  475. $.ajax({
  476. type: "get",
  477. url: huayi.config.callcenter_url + "CallInScreen/GetCurrUserDep",
  478. dataType: 'json',
  479. async: false,
  480. data: {
  481. token: $.cookie("token")
  482. },
  483. success: function(data) {
  484. if(data.state.toLowerCase() == 'success') {
  485. if(data.data.groname == '思念组') {
  486. $(".snRmove").remove();
  487. $(".dkRmove").show();
  488. } else {
  489. $(".snRmove").show();
  490. $(".dkRmove").remove();
  491. }
  492. }
  493. }
  494. });
  495. //处理状态
  496. dealState();
  497. function dealState() {
  498. $.get(huayi.config.callcenter_url + 'Dictionary/GetDicValueListByFlag', {
  499. "token": $.cookie("token"),
  500. flag: "CLZT"
  501. }, function(result) {
  502. result = $.parseJSON(result);
  503. var Count = result.data;
  504. $(Count).each(function(i, n) {
  505. $('<label style="font-weight: normal; margin-right: 15px;">'+
  506. '<input type="radio" value="' + n.F_DictionaryValueId
  507. + '" name="ltype"/>' + n.F_Name
  508. + '</label>').appendTo($(".disposeST"));
  509. })
  510. $('.disposeST input:radio:first').attr('checked', 'checked');
  511. });
  512. }
  513. //响应状态
  514. responseState();
  515. function responseState() {
  516. $.get(huayi.config.callcenter_url + 'Dictionary/GetDicValueListByFlag', {
  517. "token": $.cookie("token"),
  518. flag: "XYZT"
  519. }, function(result) {
  520. result = $.parseJSON(result);
  521. var Count = result.data;
  522. $(Count).each(function(i, n) {
  523. $('<label style="font-weight: normal; margin-right: 15px;">'+
  524. '<input type="radio" value="' + n.F_DictionaryValueId
  525. + '" name="response"/>' + n.F_Name
  526. + '</label>').appendTo($(".responseST"));
  527. })
  528. $('.responseST input:radio:first').attr('checked', 'checked');
  529. });
  530. }
  531. $("#clgd").click(function() {
  532. var val = $("input[name='ltype']:checked").val();
  533. var valRes = $("input[name='response']:checked").val();
  534. var dealCost;
  535. if (isNaN($("#dealCost").val())) {
  536. dealCost="";
  537. }else{
  538. dealCost=$("#dealCost").val();
  539. }
  540. if(!val) {
  541. layer.confirm('请选择处理方式!', {
  542. btn: ['确定']
  543. });
  544. return;
  545. }
  546. if(val == '0') {
  547. if(!$("#clbm").val()) {
  548. layer.confirm('请选择接收部门!', {
  549. btn: ['确定']
  550. });
  551. return;
  552. }
  553. }
  554. $.post(huayi.config.callcenter_url + 'WorkOrder/DealWorkOrder', {
  555. workid: zpid,
  556. dealcost: dealCost*1, //处理费用
  557. dealresult:$("#dealCont").val(),//处理结果
  558. dealdes: $("#cont").val(), //客诉进展详述
  559. dealstate:val, //处理状态
  560. dealtimely:valRes, //及时响应
  561. "token": $.cookie("token")
  562. }, function(result) {
  563. result = $.parseJSON(result);
  564. if(result.state.toLowerCase() == "success") {
  565. layer.msg("处理工单成功");
  566. $(".t-shade").removeClass("cx");
  567. $(".clgd").removeClass("cx");
  568. if(ns == 1) {
  569. $('#workorderlist').bootstrapTable('refresh');
  570. } else {
  571. $('#workorderlist_').bootstrapTable('refresh');
  572. }
  573. }
  574. })
  575. })
  576. })
  577. function initTable() {
  578. //先销毁表格
  579. $('#workorderlist').bootstrapTable('destroy');
  580. //初始化表格,动态从服务器加载数据
  581. $("#workorderlist").bootstrapTable({
  582. method: "get", //使用get请求到服务器获取数据
  583. url: huayi.config.callcenter_url + "WorkOrder/GetList", //获取数据的Servlet地址
  584. contentType: 'application/x-www-form-urlencoded',
  585. striped: true, //表格显示条纹
  586. pagination: true, //启动分页
  587. pageSize: 10, //每页显示的记录数
  588. pageNumber: 1, //当前第几页
  589. pageList: [5, 10,20, 50, 100], //记录数可选列表
  590. search: false, //是否启用查询
  591. showColumns: false, //显示下拉框勾选要显示的列
  592. showRefresh: false, //显示刷新按钮
  593. fixedColumns: true,
  594. fixedNumber: 14,
  595. columns:[{class:'ordernumber'},{class:'create_time'},{class:'W120'}
  596. ,{class:'W100'},{class:'W100'}
  597. ,{class:'W170'},{class:'W100'},{class:'W120'}
  598. ,{class:'W100'},{class:'W120'}
  599. ,{class:'W60margin'},{class:'W220'}],
  600. sidePagination: "server", //表示服务端请求
  601. //设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
  602. //设置为limit可以获取limit, offset, search, sort, order
  603. queryParamsType: "undefined",
  604. queryParams: function queryParams(params) { //设置查询参数
  605. var param = {
  606. page: params.pageNumber,
  607. pagesize: params.pageSize,
  608. state: 0,
  609. token: $.cookie("token"),
  610. // source: $('#orderSource').val(), //工单来源
  611. // producttype:$('#productTypeFilt').val(), //产品类别
  612. // province:$(".inps2").val(),
  613. definition:$("#cityName").val(),//营业厅名称
  614. strusercode:$('#typeclassId').val(),//创建人
  615. Typeof:$("#orderType").val(), //工单类型
  616. key:$('#keyWord').val(), //内容关键字
  617. workid:$('#orderNum').val(), //工单号
  618. starttime: $('#greetingTimes').val() && $('#greetingTimes').val().split(' ~ ')[0], //开始时间
  619. endtime: $('#greetingTimes').val() && $('#greetingTimes').val().split(' ~ ')[1], //结束时间
  620. // userid: $('#userid').val() //坐席
  621. };
  622. return param;
  623. },
  624. onLoadSuccess: function() { //加载成功时执行
  625. //layer.msg("加载成功");
  626. },
  627. onLoadError: function() { //加载失败时执行
  628. //layer.msg("加载数据失败", { time: 1500, icon: 2 });
  629. }
  630. });
  631. }
  632. function initTables() {
  633. //先销毁表格
  634. $('#workorderlist_').bootstrapTable('destroy');
  635. //初始化表格,动态从服务器加载数据
  636. $("#workorderlist_").bootstrapTable({
  637. method: "get", //使用get请求到服务器获取数据
  638. url: huayi.config.callcenter_url + "WorkOrder/GetList", //获取数据的Servlet地址
  639. contentType: 'application/x-www-form-urlencoded',
  640. striped: true, //表格显示条纹
  641. pagination: true, //启动分页
  642. pageSize: 10, //每页显示的记录数
  643. pageNumber: 1, //当前第几页
  644. pageList: [5, 10,20, 50, 100], //记录数可选列表
  645. search: false, //是否启用查询
  646. showColumns: false, //显示下拉框勾选要显示的列
  647. showRefresh: false, //显示刷新按钮
  648. fixedColumns: true,
  649. fixedNumber: 14,
  650. columns:[{class:'ordernumber'},{class:'create_time'},{class:'W120'}
  651. ,{class:'W150'},{class:'W150'}
  652. ,{class:'W170'},{class:'W150'},{class:'W120'}
  653. // ,{class:'W100'},{class:'W120'}
  654. ,{class:'W60margin'},{class:'W220'}],
  655. sidePagination: "server", //表示服务端请求
  656. //设置为undefined可以获取pageNumber,pageSize,searchText,sortName,sortOrder
  657. //设置为limit可以获取limit, offset, search, sort, order
  658. queryParamsType: "undefined",
  659. queryParams: function queryParams(params) { //设置查询参数
  660. var param = {
  661. page: params.pageNumber,
  662. pagesize: params.pageSize,
  663. state: 0,
  664. token: $.cookie("token"),
  665. // source: $('#orderSource').val(), //工单来源
  666. // type:$("#orderType").val(), //工单类型
  667. // producttype:$('#productTypeFilt').val(), //产品类别
  668. // strusercode:$('#typeclassId').val(),//创建人
  669. // province:$(".inps2").val(),
  670. definition:$("#cityName").val(),
  671. strusercode:$('#typeclassId').val(),
  672. Typeof:$("#orderType").val(), //工单类型
  673. key:$('#keyWord').val(), //内容关键字
  674. workid:$('#orderNum').val(), //工单号
  675. starttime: $('#greetingTimes').val() && $('#greetingTimes').val().split(' ~ ')[0], //开始时间
  676. endtime: $('#greetingTimes').val() && $('#greetingTimes').val().split(' ~ ')[1], //结束时间
  677. };
  678. return param;
  679. },
  680. onLoadSuccess: function() { //加载成功时执行
  681. //layer.msg("加载成功");
  682. },
  683. onLoadError: function() { //加载失败时执行
  684. //layer.msg("加载数据失败", { time: 1500, icon: 2 });
  685. }
  686. });
  687. }
  688. //导出
  689. function dcexcel(obj) {
  690. var url = huayi.config.callcenter_url + "WorkOrder/GetList?isdc=1&token=" + $.cookie("token");
  691. //tel来电号码 ; ltype工单状态; type工单来源; typeclass工单类型;starttime; endtime;lddep;来电单位;fkdep反馈; userid坐席工号
  692. if(stype == '1') {
  693. url += "&state=0";//状态
  694. url += "&source=" + $("#orderSource").val();//工单来源
  695. url += "&type=" + $("#orderType").val();//工单类型
  696. url += "&producttype=" + $('#productTypeFilt').val();//产品类别
  697. url += "&city=" + $('#cityName').val();//市
  698. url += "&key=" + $('#keyWord').val();//关键词
  699. url += "&workid=" + $('#orderNum').val();//关键词
  700. url += "&starttime=" + ($("#greetingTimes").val() && $("#greetingTimes").val().split(' ~ ')[0]);//开始时间
  701. url += "&endtime=" + ($("#greetingTimes").val() && $("#greetingTimes").val().split(' ~ ')[1]);//结束时间
  702. } else if(stype == '2') {
  703. url += "&name=" + $("#ss_khxm").val() + "&tel=" + $("#ss_khdh").val() + "&key=" + $("#ss_gdnr").val();
  704. url += "&type=" + $("#ss_gdlx").val() + "&orderid=" + $("#ss_gdbh").val();
  705. }
  706. obj.href = url;
  707. }
  708. function De() {
  709. return '<div class="warning" onclick="CL()">调转</div>'
  710. }
  711. function CL() {
  712. top.$("iframe:visible")[0].src = "WorkOrder/AddWorkOrder.html?id=" + id + "phone=" + phone;
  713. }
  714. var ns;
  715. $.ajax({
  716. type: "get",
  717. url: huayi.config.callcenter_url + "UserAccount/GetNowUser",
  718. dataType: 'json',
  719. async: true,
  720. data: {
  721. token: $.cookie("token")
  722. },
  723. success: function(data) {
  724. if(data.state.toLowerCase() == 'success') {
  725. if(data.data.user.F_SeartGroup == '楼上组') {
  726. $('#ce').show();
  727. // ns = 1;
  728. // $('.BZ').removeClass("Hidens");
  729. } else {
  730. $('#ces').show();
  731. // ns = 2;
  732. initTables();
  733. // $('.BZ').addClass("Hidens");
  734. }
  735. }
  736. }
  737. });
  738. </script>
  739. </body>
  740. </html>