虞城12345_前端

Source-Census.html 33KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171
  1. <!doctype html>
  2. <html lang="en" class="feedback">
  3. <head>
  4. <meta charset="UTF-8" />
  5. <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
  6. <title>数据统计</title>
  7. <link rel="stylesheet" type="text/css" href="../css/mui.min.css" />
  8. <link rel="stylesheet" type="text/css" href="../css/mui.picker.min.css" />
  9. <style>
  10. .mui-control-content {
  11. background-color: white;
  12. min-height: 215px;
  13. }
  14. .mui-control-content .mui-loading {
  15. margin-top: 50px;
  16. }
  17. .chart {
  18. height: 260px;
  19. margin: 0px;
  20. padding: 0px;
  21. }
  22. .mui-slider .mui-slider-group {
  23. height: 500px;
  24. }
  25. #CS {
  26. position: absolute;
  27. right: 0;
  28. height: 100%;
  29. padding: 0;
  30. padding-left: 5px;
  31. border: none;
  32. z-index: 30;
  33. width: 100%;
  34. }
  35. .mui-scroll {
  36. height: 100%;
  37. }
  38. #lineChart {
  39. position: absolute;
  40. top: 0;
  41. right: 0;
  42. bottom: 0;
  43. left: 0;
  44. padding: 10px;
  45. -webkit-box-sizing: border-box;
  46. box-sizing: border-box;
  47. }
  48. .mui-grid-bottom {
  49. height: 2px;
  50. background-color: #57cebf;
  51. display: block;
  52. width: 20px;
  53. margin: 0 auto;
  54. }
  55. </style>
  56. </head>
  57. <body>
  58. <header class="mui-bar mui-bar-nav">
  59. <h1 id="title" class="mui-title">来源报表</h1>
  60. <a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left" style="color: #fff;"></a>
  61. </header>
  62. <div class="mui-content ">
  63. <form id='login-form' class="mui-input-group">
  64. <!--logo-->
  65. <div class="mui-input-row">
  66. <label>来源:</label>
  67. <select name="" class="mui-select">
  68. </select>
  69. </div>
  70. <div class="mui-input-row mui-password">
  71. <label>时间:</label>
  72. <!--<input id='password' type="datetime-local" class=" mui-input" >-->
  73. <input id='demo1' data-options='{}' type="text" class="mui-input-clear btn contact" />
  74. </div>
  75. </form>
  76. <div id="slider" class="mui-slider">
  77. <div id="sliderSegmentedControl" class="mui-slider-indicator mui-segmented-control mui-segmented-control-inverted">
  78. <a class="mui-control-item mui-active" href="#item1mobile" index="1">
  79. 日报
  80. </a>
  81. <a class="mui-control-item" href="#item2mobile" index="2">
  82. 周报
  83. </a>
  84. <a class="mui-control-item" href="#item3mobile" index="3">
  85. 月报
  86. </a>
  87. </div>
  88. <div class="mui-slider-group">
  89. <div id="item1mobile" class="mui-slider-item mui-control-content mui-active">
  90. <div id="scroll1" class="mui-scroll-wrapper">
  91. <div class="mui-scroll">
  92. <div class="chart" id="pieChart"></div>
  93. <div>
  94. <ul class="mui-table-view mui-grid-view mui-grid-9">
  95. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  96. <a href="#">
  97. <span class="size-20" id="jsblrate"></span>
  98. <div class="mui-media-body size-14">即时办理率</div>
  99. </a>
  100. <span class="mui-grid-bottom"></span>
  101. </li>
  102. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  103. <a href="#">
  104. <span class="size-20" id="wlzbrate"></span>
  105. <div class="mui-media-body size-14">转办率</div>
  106. </a>
  107. <span class="mui-grid-bottom"></span>
  108. </li>
  109. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  110. <a href="#">
  111. <span class="size-20" id="zbbjrate"></span>
  112. <div class="mui-media-body size-14">转办办结率</div>
  113. </a>
  114. <span class="mui-grid-bottom"></span>
  115. </li>
  116. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  117. <a href="#">
  118. <span class="size-20" id="bjrate"></span>
  119. <div class="mui-media-body size-14">办结率</div>
  120. </a>
  121. <span class="mui-grid-bottom"></span>
  122. </li>
  123. </ul>
  124. </div>
  125. </div>
  126. </div>
  127. </div>
  128. <div id="item2mobile" class="mui-slider-item mui-control-content">
  129. <div id="scroll2" class="mui-scroll-wrapper">
  130. <div class="mui-scroll">
  131. <div class="chart" id="barChart"></div>
  132. <div>
  133. <ul class="mui-table-view mui-grid-view mui-grid-9">
  134. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  135. <a href="#">
  136. <span class="size-20" id="week-jsblrate"></span>
  137. <div class="mui-media-body size-14">即时办理率</div>
  138. </a>
  139. </li>
  140. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  141. <a href="#">
  142. <span class="size-20" id="week-wlzbrate"></span>
  143. <div class="mui-media-body size-14">转办率</div>
  144. </a>
  145. </li>
  146. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  147. <a href="#">
  148. <span class="size-20" id="week-zbbjrate"></span>
  149. <div class="mui-media-body size-14">转办办结率</div>
  150. </a>
  151. </li>
  152. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  153. <a href="#">
  154. <span class="size-20" id="week-bjrate"></span>
  155. <div class="mui-media-body size-14">办结率</div>
  156. </a>
  157. </li>
  158. </ul>
  159. </div>
  160. </div>
  161. </div>
  162. </div>
  163. <div id="item3mobile" class="mui-slider-item mui-control-content">
  164. <div id="scroll2" class="mui-scroll-wrapper">
  165. <div class="mui-scroll">
  166. <div class="chart" id="Chart">5555</div>
  167. <div>
  168. <ul class="mui-table-view mui-grid-view mui-grid-9">
  169. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  170. <a href="#">
  171. <span class="size-20" id="month-jsblrate"></span>
  172. <div class="mui-media-body size-14">即时办理率</div>
  173. </a>
  174. </li>
  175. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  176. <a href="#">
  177. <span class="size-20" id="month-wlzbrate"></span>
  178. <div class="mui-media-body size-14">转办率</div>
  179. </a>
  180. </li>
  181. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  182. <a href="#">
  183. <span class="size-20" id="month-zbbjrate"></span>
  184. <div class="mui-media-body size-14">转办办结率</div>
  185. </a>
  186. </li>
  187. <li class="mui-table-view-cell mui-media mui-col-xs-6 ">
  188. <a href="#">
  189. <span class="size-20" id="month-bjrate"></span>
  190. <div class="mui-media-body size-14">办结率</div>
  191. </a>
  192. </li>
  193. </ul>
  194. </div>
  195. </div>
  196. </div>
  197. </div>
  198. </div>
  199. </div>
  200. </div>
  201. <script src="../js/zepto.js"></script>
  202. <script src="../js/mui.min.js"></script>
  203. <script src="../js/echarts.common.min.js"></script>
  204. <script src="../js/huayi.config.js"></script>
  205. <script src="../js/mui.picker.min.js"></script>
  206. <script type="text/javascript">
  207. mui.init();
  208. window.onload = function() {
  209. mui('.mui-scroll-wrapper').scroll({
  210. deceleration: 0.0005 //flick 减速系数,系数越大,滚动速度越慢,滚动距离越小,默认值0.0006
  211. });
  212. }
  213. var usercode = localStorage.getItem("user"); //获取本地存储
  214. var goodslist;
  215. var index_=1;
  216. //本周图表
  217. var xAxis = [];
  218. var yAxis = [];
  219. var yAxiss = [];
  220. //本月
  221. var xAxis_math = [];
  222. var yAxis_math = [];
  223. var yAxiss_math = []
  224. mui.plusReady(function() {
  225. var wv = plus.webview.currentWebview();
  226. var index = wv.index;
  227. plus.nativeUI.closeWaiting();
  228. //显示当前页面
  229. mui.currentWebview.show();
  230. //下拉框
  231. $.ajax({
  232. type: "get",
  233. url: huayi.config.callcenter_url + '/APP/GetDicValueList',
  234. async: false,
  235. dataType: 'json',
  236. data: {
  237. usercode: usercode,
  238. },
  239. success: function(data) {
  240. console.log(data.state);
  241. if(data.state == "success") {
  242. goodslist = data.data;
  243. bindseat($(".mui-select"));
  244. }
  245. },
  246. error: function(data) {
  247. console.log(data.message);
  248. }
  249. });
  250. //下拉框
  251. function bindseat(obj) {
  252. obj.empty();
  253. // obj.append('<option value="0" selected="true">所有来源</option>');
  254. $(goodslist).each(function(i, n) {
  255. obj.append('<option value="' + n.F_ValueId + '">' + n.F_Value + '</option>');
  256. })
  257. }
  258. //日期
  259. var dates = new Date();
  260. var time = dates.getFullYear() + "-" + (dates.getMonth() + 1) + '-' + dates.getDate();
  261. $("#demo1").val(time);
  262. //时间选择
  263. var btns = mui('.btn');
  264. btns.each(function(i, btn) {  
  265. btn.addEventListener('tap', function() {   
  266. var dtPicker = new mui.DtPicker({    
  267. type: "date", //设置日历初始视图模式
  268.   
  269. });  
  270. dtPicker.show(function(e) {
  271. $("#demo1").val(e);
  272. AreaL();//日报
  273. AreaLs();//周报
  274. }); 
  275. }, false);
  276. })
  277. AreaL();
  278. $(".mui-select").on('change', function() {
  279. console.log($('.mui-select').val());
  280. AreaL();//日报
  281. AreaLs();//周报
  282. Month();//月报
  283. })
  284. //日报的数据
  285. function AreaL() {
  286. console.log($('.mui-select').val());
  287. $.ajax({
  288. type: "get",
  289. url: huayi.config.callcenter_url + '/app/GetAPPWorkReportSingle',
  290. async: true,
  291. dataType: 'json',
  292. data: {
  293. usercode: usercode,
  294. datetype: index_,
  295. date: $("#demo1").val(),
  296. datatype:index,
  297. dataid: $('.mui-select').val()
  298. },
  299. success: function(data) {
  300. if(data.state == "success") {
  301. var Data = data.data.APPDayWeekMonthReportSingle[0];
  302. // alert(JSON.stringify(Data));
  303. $("#bjrate").text(Data.bjrate)
  304. $("#jsblrate").text(Data.jsblrate);
  305. $("#wlzbrate").text(Data.wlzbrate);
  306. $("#zbbjrate").text(Data.zbbjrate);
  307. var option = {
  308. tooltip: {
  309. formatter: "{b} : {c} ({d}%)"
  310. },
  311. legend: {
  312. orient: 'vertical',
  313. top: 'middle',
  314. x: 'top',
  315. left: 10,
  316. top: 3,
  317. data: ['即时办结', '网络转办', '转办办结']
  318. },
  319. series: [{
  320. type: 'pie',
  321. radius: '55%',
  322. selectedMode: 'single',
  323. center: ['50%', '60%'],
  324. label: {
  325. normal: {
  326. formatter: "{b} : {c} ",
  327. }
  328. },
  329. labelLine: {
  330. normal: {
  331. show: false
  332. }
  333. },
  334. data: [{
  335. value: data.data.APPDayWeekMonthReportSingle[0].jsblcount,
  336. name: '即时办结',
  337. },
  338. {
  339. value: data.data.APPDayWeekMonthReportSingle[0].wlzbcount,
  340. name: '网络转办',
  341. },
  342. {
  343. value: data.data.APPDayWeekMonthReportSingle[0].zbbjcount,
  344. name: '转办办结',
  345. }
  346. ],
  347. }]
  348. };
  349. echartsPie = echarts.init(document.getElementById('pieChart'));
  350. echartsPie.setOption(option);
  351. }
  352. },
  353. error: function(data) {
  354. console.log(data.message);
  355. }
  356. });
  357. }
  358. AreaLs();
  359. Month();
  360. //周报
  361. function AreaLs() {
  362. console.log($('.mui-select').val());
  363. $.ajax({
  364. type: "get",
  365. url: huayi.config.callcenter_url + '/app/GetAPPWorkReportSingle',
  366. async: true,
  367. dataType: 'json',
  368. data: {
  369. usercode: usercode,
  370. datetype: 2,
  371. date: $("#demo1").val(),
  372. datatype:index,
  373. dataid: $('.mui-select').val()
  374. },
  375. success: function(data) {
  376. if(data.state == "success") {
  377. var Data = data.data.APPDayWeekMonthReportSingle[0];
  378. $("#week-bjrate").text(Data.bjrate)
  379. $("#week-jsblrate").text(Data.jsblrate);
  380. $("#week-wlzbrate").text(Data.wlzbrate);
  381. $("#week-zbbjrate").text(Data.zbbjrate);
  382. var option = {
  383. tooltip: {
  384. formatter: "{b} : {c} ({d}%)"
  385. },
  386. legend: {
  387. orient: 'vertical',
  388. top: 'middle',
  389. x: 'left',
  390. left: 5,
  391. top: 5,
  392. data: ['即时办结', '网络转办', '转办办结']
  393. },
  394. series: [{
  395. type: 'pie',
  396. radius: '55%',
  397. selectedMode: 'single',
  398. center: ['50%', '60%'],
  399. label: {
  400. normal: {
  401. formatter: "{a} {b} : {c} ",
  402. }
  403. },
  404. labelLine: {
  405. normal: {
  406. show: false
  407. }
  408. },
  409. data: [{
  410. value: data.data.APPDayWeekMonthReportSingle[0].jsblcount,
  411. name: '即时办结',
  412. },
  413. {
  414. value: data.data.APPDayWeekMonthReportSingle[0].wlzbcount,
  415. name: '网络转办',
  416. },
  417. {
  418. value: data.data.APPDayWeekMonthReportSingle[0].zbbjcount,
  419. name: '转办办结',
  420. }
  421. ],
  422. }]
  423. };
  424. echartsPie = echarts.init(document.getElementById('barChart'));
  425. echartsPie.setOption(option);
  426. }
  427. },
  428. error: function(data) {
  429. console.log(data.message);
  430. }
  431. });
  432. }
  433. //月报
  434. function Month(){
  435. console.log($('.mui-select').val());
  436. $.ajax({
  437. type: "get",
  438. url: huayi.config.callcenter_url + '/app/GetAPPWorkReportSingle',
  439. async: true,
  440. dataType: 'json',
  441. data: {
  442. usercode: usercode,
  443. datetype: 3,
  444. date: $("#demo1").val(),
  445. datatype:index,
  446. dataid: $('.mui-select').val()
  447. },
  448. success: function(data) {
  449. if(data.state == "success") {
  450. var Data = data.data.APPDayWeekMonthReportSingle[0];
  451. $("#month-bjrate").text(Data.bjrate)
  452. $("#month-jsblrate").text(Data.jsblrate);
  453. $("#month-wlzbrate").text(Data.wlzbrate);
  454. $("#month-zbbjrate").text(Data.zbbjrate);
  455. var option = {
  456. tooltip: {
  457. formatter: "{a} <br/>{b} : {c} ({d}%)"
  458. },
  459. legend: {
  460. orient: 'vertical',
  461. x: 'left',
  462. left: 5,
  463. top: 5,
  464. data: ['即时办结', '网络转办', '转办办结']
  465. },
  466. series: [{
  467. type: 'pie',
  468. radius: '55%',
  469. selectedMode: 'single',
  470. center: ['50%', '60%'],
  471. label: {
  472. normal: {
  473. formatter: "{a} {b} : {c} ",
  474. }
  475. },
  476. labelLine: {
  477. normal: {
  478. show: false
  479. }
  480. },
  481. data: [{
  482. value: data.data.APPDayWeekMonthReportSingle[0].jsblcount,
  483. name: '即时办结',
  484. },
  485. {
  486. value: data.data.APPDayWeekMonthReportSingle[0].wlzbcount,
  487. name: '网络转办',
  488. },
  489. {
  490. value: data.data.APPDayWeekMonthReportSingle[0].zbbjcount,
  491. name: '转办办结',
  492. }
  493. ],
  494. }]
  495. };
  496. echartsPie = echarts.init(document.getElementById('Chart'));
  497. echartsPie.setOption(option);
  498. }
  499. },
  500. error: function(data) {
  501. console.log(data.message);
  502. }
  503. });
  504. }
  505. //切换
  506. $(".mui-control-item").on('tap',function(){
  507. var indexs=$(this).attr('index');
  508. index_=indexs;
  509. AreaL();
  510. AreaLs();
  511. Month();
  512. })
  513. //本周
  514. // $.ajax({
  515. // type: "get",
  516. // url: huayi.config.callcenter_url + 'WorkOrder/GetWeekReport',
  517. // async: true,
  518. // dataType: 'json',
  519. // data: {
  520. // openid: 'oKOqcv31fh76rtNmJDjKc39oIsfA'
  521. // },
  522. // success: function(data) {
  523. // console.log(data.state);
  524. // if(data.state == "success") {
  525. // console.log(data.data[0].unfinish);
  526. // $("#Workfinish").text(data.data[7].finish);
  527. // $("#Workunfinifh").text(data.data[7].unfinish);
  528. // $("#WorkTotal").text(data.data[7].finish + data.data[0].unfinish);
  529. // for(var i = 0; i < data.data.length; i++) {
  530. // xAxis.push(data.data[i].ID);
  531. //
  532. // yAxis.push(data.data[i].unfinish);
  533. // yAxiss.push(data.data[i].finish)
  534. // }
  535. //
  536. // var option = {
  537. // grid: {
  538. // x: 35,
  539. // x2: 10,
  540. // y: 30,
  541. // y2: 25,
  542. // borderWidth: 0
  543. // },
  544. // toolbox: {
  545. // show: false,
  546. // feature: {
  547. // mark: {
  548. // show: true
  549. // },
  550. // dataView: {
  551. // show: true,
  552. // readOnly: false
  553. // },
  554. // magicType: {
  555. // show: true,
  556. // type: ['line', 'bar']
  557. // },
  558. // restore: {
  559. // show: true
  560. // },
  561. // saveAsImage: {
  562. // show: true
  563. // }
  564. // }
  565. // },
  566. // legend: {
  567. // top: 20,
  568. // data: ['已完成', '未完成', ]
  569. // },
  570. //
  571. // calculable: false,
  572. // xAxis: [{
  573. // axisLabel: {
  574. // interval: 0
  575. // },
  576. //
  577. // splitArea: {
  578. // show: false,
  579. // },
  580. // splitLine: {
  581. // show: false
  582. // }, //去除网格线
  583. // type: 'category',
  584. // data: xAxis
  585. // }],
  586. // yAxis: [{
  587. // show: false,
  588. // splitLine: {
  589. // show: false
  590. // }, //去除网格线
  591. // type: 'value',
  592. // splitArea: {
  593. // show: false,
  594. // }
  595. // }],
  596. // series: [{
  597. // name: '已完成',
  598. // type: 'bar',
  599. // barWidth: 10, //柱图宽度
  600. // itemStyle: {
  601. // normal: {
  602. // label: {
  603. // show: true
  604. // }
  605. // }
  606. // },
  607. // data: yAxis
  608. // }, {
  609. // name: '未完成',
  610. // type: 'bar',
  611. // barWidth: 10, //柱图宽度
  612. // itemStyle: {
  613. // normal: {
  614. // label: {
  615. // show: true
  616. // }
  617. // }
  618. // },
  619. // data: yAxiss
  620. // }]
  621. // };
  622. // echartsPie = echarts.init(document.getElementById('barChart'));
  623. // echartsPie.setOption(option);
  624. // }
  625. //
  626. // },
  627. // error: function(data) {
  628. // console.log(data.message);
  629. // }
  630. // });
  631. //本月
  632. // $.ajax({
  633. // type: "get",
  634. // url: huayi.config.callcenter_url + 'WorkOrder/GetMonthReport',
  635. // async: true,
  636. // dataType: 'json',
  637. // data: {
  638. // openid: 'oKOqcv31fh76rtNmJDjKc39oIsfA'
  639. // },
  640. // success: function(data) {
  641. // console.log(data.state);
  642. // if(data.state == "success") {
  643. // console.log(data.data[0].unfinish);
  644. // $("#Workfinish").text(data.data[7].finish);
  645. // $("#Workunfinifh").text(data.data[7].unfinish);
  646. // $("#WorkTotal").text(data.data[7].finish + data.data[0].unfinish);
  647. // for(var i = 0; i < data.data.length; i++) {
  648. // xAxis_math.push(data.data[i].ID);
  649. //
  650. // yAxis_math.push(data.data[i].unfinish);
  651. // yAxiss_math.push(data.data[i].finish)
  652. // }
  653. //
  654. // // var option = {
  655. // // grid: {
  656. // // x: 35,
  657. // // x2: 10,
  658. // // y: 30,
  659. // // y2: 50,
  660. // // borderWidth: 0
  661. // // },
  662. // // toolbox: {
  663. // // show: false,
  664. // // feature: {
  665. // // mark: {
  666. // // show: true
  667. // // },
  668. // // dataView: {
  669. // // show: true,
  670. // // readOnly: false
  671. // // },
  672. // // magicType: {
  673. // // show: true,
  674. // // type: ['line', 'bar']
  675. // // },
  676. // // restore: {
  677. // // show: true
  678. // // },
  679. // // saveAsImage: {
  680. // // show: true
  681. // // }
  682. // // }
  683. // // },
  684. // // legend: {
  685. // //
  686. // // data: ['已完成', '未完成', ]
  687. // // },
  688. // //
  689. // // calculable: false,
  690. // // xAxis: [{
  691. // // axisLabel: {
  692. // // interval: 10
  693. // // },
  694. // // axisLabel: {
  695. // // rotate: 45, //字体倾斜度数
  696. // // interval: 0, //interval 是指间隔多少个类别画栅格,为 0 时则每个数据都画,为 1 时间隔 1 个画,以此类推
  697. // // textStyle: {
  698. // // color: "red", //字体颜色
  699. // // fontSize: 10 //字体大小
  700. // // }
  701. // // },
  702. // // splitArea: {
  703. // // show: false,
  704. // // },
  705. // // splitLine: {
  706. // // show: false
  707. // // }, //去除网格线
  708. // // type: 'category',
  709. // // data:xAxis_math
  710. // // }],
  711. // // yAxis: [{
  712. // // show: false,
  713. // // splitLine: {
  714. // // show: false
  715. // // }, //去除网格线
  716. // // type: 'value',
  717. // // splitArea: {
  718. // // show: false,
  719. // // }
  720. // // }],
  721. // // series: [{
  722. // // name: '已完成',
  723. // // type: 'bar',
  724. // // barWidth: 10, //柱图宽度
  725. // // itemStyle: {
  726. // // normal: {
  727. // // label: {
  728. // // show: true
  729. // // }
  730. // // }
  731. // // },
  732. // // data: yAxis_math,
  733. // //
  734. // // },
  735. // // {
  736. // // name: '未完成',
  737. // // type: 'bar',
  738. // // barWidth: 5, //柱图宽度
  739. // // itemStyle: {
  740. // // normal: {
  741. // // label: {
  742. // // show: true
  743. // // }
  744. // // }
  745. // // },
  746. // // data: yAxiss_math,
  747. // //
  748. // // }
  749. // // ]
  750. // // };
  751. //
  752. // var option = {
  753. // tooltip: {
  754. // trigger: 'axis',
  755. // axisPointer: {
  756. // type: 'shadow'
  757. // }
  758. // },
  759. // legend: {
  760. // data: ['未完成', '已完成']
  761. // },
  762. // grid: {
  763. // left: '3%',
  764. // right: '4%',
  765. // bottom: '3%',
  766. // containLabel: true
  767. // },
  768. // xAxis: {
  769. // type: 'value',
  770. // boundaryGap: [0, 0.01]
  771. // },
  772. // yAxis: {
  773. // type: 'category',
  774. // data: xAxis_math
  775. // },
  776. // series: [{
  777. // name: '未完成',
  778. // type: 'bar',
  779. // barWidth: 10,
  780. // data: yAxis_math
  781. // },
  782. // {
  783. // name: '已完成',
  784. // type: 'bar',
  785. // barWidth: 10,
  786. // data: yAxiss_math
  787. // }
  788. // ]
  789. // };
  790. // echartsPie = echarts.init(document.getElementById('lineChart'));
  791. // echartsPie.setOption(option);
  792. // }
  793. //
  794. // },
  795. // error: function(data) {
  796. // console.log(data.message);
  797. // }
  798. // });
  799. ///全部
  800. // $.ajax({
  801. // type: "get",
  802. // url: huayi.config.callcenter_url + 'WorkOrder/GetTotalReport',
  803. // async: true,
  804. // dataType: 'json',
  805. // data: {
  806. // openid: 'oKOqcv31fh76rtNmJDjKc39oIsfA'
  807. // },
  808. // success: function(data) {
  809. // console.log(data.state);
  810. // if(data.state == "success") {
  811. // console.log(data.data[0].unfinish);
  812. // $("#finish").text(data.data[0].finish);
  813. // $("#unfinifh").text(data.data[0].unfinish);
  814. // $("#RTotal").text(data.data[0].finish + data.data[0].unfinish);
  815. // var option = {
  816. // tooltip: {
  817. // formatter: "{a} <br/>{b} : {c} ({d}%)"
  818. // },
  819. // legend: {
  820. // orient: 'vertical',
  821. // // top: 'middle',
  822. //
  823. // x: 'left',
  824. // left: 25,
  825. // top: 80,
  826. // data: ['未完成', '已完成']
  827. // },
  828. // series: [{
  829. // type: 'pie',
  830. // radius: '65%',
  831. // center: ['50%', '50%'],
  832. // selectedMode: 'single',
  833. // data: [
  834. //
  835. // {
  836. // value: data.data[0].unfinish,
  837. // name: '未完成',
  838. // label: {
  839. // normal: {
  840. // formatter: "{b}: {c} ({d}%)"
  841. // }
  842. // }
  843. // },
  844. // {
  845. // value: data.data[0].finish,
  846. // name: '已完成',
  847. // label: {
  848. // normal: {
  849. // formatter: "{b}: {c} ({d}%)"
  850. // }
  851. // }
  852. // }
  853. //
  854. // ],
  855. // itemStyle: {
  856. // emphasis: {
  857. // shadowBlur: 10,
  858. // shadowOffsetX: 0,
  859. // shadowColor: 'rgba(0, 0, 0, 0.5)'
  860. // }
  861. // }
  862. // }]
  863. // };
  864. //
  865. // echartsPie = echarts.init(document.getElementById('lineCharts'));
  866. // echartsPie.setOption(option);
  867. // }
  868. //
  869. // },
  870. // error: function(data) {
  871. // console.log(data.message);
  872. // }
  873. // });
  874. //分类
  875. // $.ajax({
  876. // type: "get",
  877. // url: huayi.config.callcenter_url + 'WorkOrder/GetReportByFL',
  878. // async: true,
  879. // dataType: 'json',
  880. // data: {
  881. // openid: 'oKOqcv31fh76rtNmJDjKc39oIsfA'
  882. // },
  883. // success: function(data) {
  884. // console.log(data.state);
  885. // if(data.state == "success") {
  886. // console.log(data.data[0].unfinish);
  887. // var xAxis_fl = [];
  888. // var yAxis_ = [];
  889. // var yAxiss_ = [];
  890. // // $("#Workfinish").text(data.data[7].finish);
  891. // // $("#Workunfinifh").text(data.data[7].unfinish);
  892. // // $("#WorkTotal").text(data.data[7].finish + data.data[0].unfinish);
  893. // for(var i = 0; i < data.data.length; i++) {
  894. // xAxis_fl.push(data.data[i].fl);
  895. // yAxis_.push(data.data[i].unfinish);
  896. // yAxiss_.push(data.data[i].finish)
  897. // }
  898. // console.log(yAxis_);
  899. // var option = {
  900. // grid: {
  901. // x: 35,
  902. // x2: 10,
  903. // y: 30,
  904. // y2: 50,
  905. // borderWidth: 0
  906. // },
  907. // toolbox: {
  908. // show: false,
  909. // feature: {
  910. // mark: {
  911. // show: true
  912. // },
  913. // dataView: {
  914. // show: true,
  915. // readOnly: false
  916. // },
  917. // magicType: {
  918. // show: true,
  919. // type: ['line', 'bar']
  920. // },
  921. // restore: {
  922. // show: true
  923. // },
  924. // saveAsImage: {
  925. // show: true
  926. // }
  927. // }
  928. // },
  929. // legend: {
  930. // top: 20,
  931. // data: ['已完成', '未完成', ]
  932. // },
  933. //
  934. // calculable: false,
  935. // xAxis: [{
  936. // axisLabel: {
  937. // interval: 0
  938. // },
  939. // axisLabel: {
  940. // rotate: 40, //字体倾斜度数
  941. // interval: 0, //interval 是指间隔多少个类别画栅格,为 0 时则每个数据都画,为 1 时间隔 1 个画,以此类推
  942. // textStyle: {
  943. // color: "red", //字体颜色
  944. // fontSize: 10 //字体大小
  945. // }
  946. // },
  947. // splitArea: {
  948. // show: false,
  949. // },
  950. // splitLine: {
  951. // show: false
  952. // }, //去除网格线
  953. // type: 'category',
  954. // data: xAxis_fl
  955. // }],
  956. // yAxis: [{
  957. // show: false,
  958. // splitLine: {
  959. // show: false
  960. // }, //去除网格线
  961. // type: 'value',
  962. // splitArea: {
  963. // show: false,
  964. // }
  965. // }],
  966. // series: [{
  967. // name: '已完成',
  968. // type: 'bar',
  969. // barWidth: 10, //柱图宽度
  970. // itemStyle: {
  971. // normal: {
  972. // label: {
  973. // show: true
  974. // }
  975. // }
  976. // },
  977. // data: yAxiss_
  978. // }, {
  979. // name: '未完成',
  980. // type: 'bar',
  981. // barWidth: 10, //柱图宽度
  982. // itemStyle: {
  983. // normal: {
  984. // label: {
  985. // show: true
  986. // }
  987. // }
  988. // },
  989. // data: yAxis_
  990. // }]
  991. // };
  992. // echartsPie = echarts.init(document.getElementById('bar-Chart'));
  993. // echartsPie.setOption(option);
  994. // }
  995. //
  996. // },
  997. // error: function(data) {
  998. // console.log(data.message);
  999. // }
  1000. // });
  1001. //部门
  1002. // $.ajax({
  1003. // type: "get",
  1004. // url: huayi.config.callcenter_url + 'WorkOrder/GetReportByDept',
  1005. // async: true,
  1006. // dataType: 'json',
  1007. // data: {
  1008. // openid: 'oKOqcv31fh76rtNmJDjKc39oIsfA'
  1009. // },
  1010. // success: function(data) {
  1011. // console.log(data.state);
  1012. // if(data.state == "success") {
  1013. // console.log(data.data[0].unfinish);
  1014. // var xAxis_fl = [];
  1015. // var yAxis_ = [];
  1016. // var yAxiss_ = [];
  1017. // // $("#Workfinish").text(data.data[7].finish);
  1018. // // $("#Workunfinifh").text(data.data[7].unfinish);
  1019. // // $("#WorkTotal").text(data.data[7].finish + data.data[0].unfinish);
  1020. // for(var i = 0; i < data.data.length; i++) {
  1021. // xAxis_fl.push(data.data[i].dept);
  1022. // yAxis_.push(data.data[i].unfinish);
  1023. // yAxiss_.push(data.data[i].finish)
  1024. // }
  1025. //
  1026. // var option = {
  1027. // grid: {
  1028. // x: 35,
  1029. // x2: 10,
  1030. // y: 30,
  1031. // y2: 50,
  1032. // borderWidth: 0
  1033. // },
  1034. // toolbox: {
  1035. // show: false,
  1036. // feature: {
  1037. // mark: {
  1038. // show: true
  1039. // },
  1040. // dataView: {
  1041. // show: true,
  1042. // readOnly: false
  1043. // },
  1044. // magicType: {
  1045. // show: true,
  1046. // type: ['line', 'bar']
  1047. // },
  1048. // restore: {
  1049. // show: true
  1050. // },
  1051. // saveAsImage: {
  1052. // show: true
  1053. // }
  1054. // }
  1055. // },
  1056. // legend: {
  1057. // top: 20,
  1058. // data: ['已完成', '未完成', ]
  1059. // },
  1060. //
  1061. // calculable: false,
  1062. // xAxis: [{
  1063. // axisLabel: {
  1064. // interval: 0
  1065. // },
  1066. // axisLabel: {
  1067. // rotate: 40, //字体倾斜度数
  1068. // interval: 0, //interval 是指间隔多少个类别画栅格,为 0 时则每个数据都画,为 1 时间隔 1 个画,以此类推
  1069. // textStyle: {
  1070. // color: "red", //字体颜色
  1071. // fontSize: 10 //字体大小
  1072. // }
  1073. // },
  1074. // splitArea: {
  1075. // show: false,
  1076. // },
  1077. // splitLine: {
  1078. // show: false
  1079. // }, //去除网格线
  1080. // type: 'category',
  1081. // data: xAxis_fl
  1082. // }],
  1083. // yAxis: [{
  1084. // show: false,
  1085. // splitLine: {
  1086. // show: false
  1087. // }, //去除网格线
  1088. // type: 'value',
  1089. // splitArea: {
  1090. // show: false,
  1091. // }
  1092. // }],
  1093. // series: [{
  1094. // name: '已完成',
  1095. // type: 'bar',
  1096. // barWidth: 10, //柱图宽度
  1097. // itemStyle: {
  1098. // normal: {
  1099. // label: {
  1100. // show: true
  1101. // }
  1102. // }
  1103. // },
  1104. // data: yAxis_
  1105. // }, {
  1106. // name: '未完成',
  1107. // type: 'bar',
  1108. // barWidth: 10, //柱图宽度
  1109. // itemStyle: {
  1110. // normal: {
  1111. // label: {
  1112. // show: true
  1113. // }
  1114. // }
  1115. // },
  1116. // data: yAxiss_
  1117. // }]
  1118. // };
  1119. // echartsPie = echarts.init(document.getElementById('bar-Chart2'));
  1120. // echartsPie.setOption(option);
  1121. // }
  1122. //
  1123. // },
  1124. // error: function(data) {
  1125. // console.log(data.message);
  1126. // }
  1127. // });
  1128. //获取区域
  1129. });
  1130. </script>
  1131. </body>
  1132. </html>