view.html 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711
  1. {extend name="common/common2" /}
  2. {block name="main"}
  3. <style>
  4. h1{
  5. font-size: 40px;
  6. margin-bottom: 25px;
  7. }
  8. h3{
  9. font-size: 22px;
  10. }
  11. .main .main-title{
  12. width: 111px;
  13. height: 18px;
  14. font-size: 18px;
  15. font-family: Source Han Sans CN;
  16. font-weight: 500;
  17. color: #354655;
  18. padding-left: 20px;
  19. }
  20. .money{
  21. height: 136px;
  22. background: linear-gradient(0deg, #FCCDBA, #F8CA9D);
  23. box-shadow: 0px 14px 20px 0px rgba(233, 94, 0, 0.1);
  24. border-radius: 30px;
  25. margin-top: 15px;
  26. }
  27. .money .money-img .money-title{
  28. width: 200px;
  29. height: 17px;
  30. font-size: 18px;
  31. font-family: Source Han Sans CN;
  32. font-weight: 500;
  33. color: #FFFFFF;
  34. margin-left: 65px;
  35. margin-top: -41px;
  36. }
  37. .money .money-num{
  38. width: 100%;
  39. height: 37px;
  40. font-size: 30px;
  41. font-family: Yuanti SC;
  42. font-weight: bold;
  43. color: #FFFFFF;
  44. line-height: 18px;
  45. text-shadow: 0px 4px 0px rgba(0, 0, 0, 0.1);
  46. margin-top: 22px;
  47. text-align: right;
  48. padding: 0 30px;
  49. }
  50. .money-img{
  51. padding-top: 10px;
  52. height: 57px;
  53. width: 100%;
  54. margin-left: 10px;
  55. }
  56. .order-view{
  57. width: 100%;
  58. height: 100px;
  59. }
  60. .percent{
  61. position: absolute;
  62. width: 40px;
  63. height: 15px;
  64. font-size: 24px;
  65. font-family: Source Han Sans CN;
  66. font-weight: bold;
  67. color: #666666;
  68. top: 85px;
  69. left: 90px;
  70. }
  71. .ov{
  72. margin-left:10px;
  73. }
  74. .z-line{
  75. margin-top: 20px;
  76. }
  77. .progress-cus{
  78. background-color: #E7E7E7;
  79. }
  80. .line-title .line-title2{
  81. margin-left: 10px;
  82. width: 55px;
  83. height: 15px;
  84. font-size: 20px;
  85. font-family: Source Han Sans CN;
  86. font-weight: bold;
  87. color: #148d8f;
  88. }
  89. .line-desc-nums{
  90. width: 57px;
  91. height: 31px;
  92. font-size: 42px;
  93. font-family: Yuanti SC;
  94. font-weight: bold;
  95. color: #666666;
  96. }
  97. .line-radio1{
  98. background: #E7E7E7;
  99. width: 10px;
  100. height: 10px;
  101. border-radius: 50%;
  102. }
  103. .line-radio2{
  104. background: #148d8f;
  105. width: 10px;
  106. height: 10px;
  107. border-radius: 50%;
  108. }
  109. .line-desc1{
  110. width: 114px;
  111. float: left;
  112. }
  113. .worker{
  114. text-align: center;
  115. }
  116. .worker-num1{
  117. width: 100%;
  118. height: 28px;
  119. font-size: 38px;
  120. font-family: Yuanti SC;
  121. font-weight: bold;
  122. color: #FDAB29;
  123. text-align: center;
  124. }
  125. .worker-num2{
  126. width: 100%;
  127. height: 28px;
  128. font-size: 38px;
  129. font-family: Yuanti SC;
  130. font-weight: bold;
  131. color: #148d8f;
  132. text-align: center;
  133. }
  134. .worker-num3{
  135. width: 100%;
  136. height: 28px;
  137. font-size: 38px;
  138. font-family: Yuanti SC;
  139. font-weight: bold;
  140. color: #426EFD;
  141. text-align: center;
  142. }
  143. .worker-title1{
  144. width: 100%;
  145. height: 16px;
  146. font-size: 16px;
  147. font-family: Source Han Sans CN;
  148. font-weight: 400;
  149. color: #666666;
  150. margin-top: 35px;
  151. text-align: center;
  152. }
  153. .worker-list{
  154. margin-top: 100px;
  155. text-align: center;
  156. }
  157. .worker-list tr th{
  158. text-align: center;
  159. background: #EBF8F5;
  160. color: #148d8f;
  161. }
  162. .worker-list tr td{
  163. text-align: center;
  164. }
  165. #ks-order{
  166. width: 100%;
  167. height: 300px;
  168. }
  169. .month{
  170. float: right;
  171. }
  172. .line-desc-title{
  173. line-height: 10px;
  174. }
  175. .line-desc-title1{
  176. margin-left: 10px;
  177. margin-top: -8px;
  178. }
  179. </style>
  180. <!--<div class="panel panel-default" style="background-color: #F6FAF9;">-->
  181. <!-- <div class="panel-body">-->
  182. <!-- <div class="col-xs-8">-->
  183. <!-- <h1><strong>{:get_config('web_site_title')}陪护平台</strong></h1>-->
  184. <!-- <h3>欢迎您 {:session('user_auth.real_name')} 您最近一次登陆的时间是{:session('user_auth.last_login_time')}</h3>-->
  185. <!-- <div style="padding-top: 20px">-->
  186. <!-- <a href="">陪护后台管理操作说明书.pdf</a>-->
  187. <!-- &nbsp;&nbsp;&nbsp;-->
  188. <!-- <a href="">陪护用户端操作说明书.pdf</a>-->
  189. <!-- </div>-->
  190. <!-- </div>-->
  191. <!-- <div class="col-xs-2" >-->
  192. <!-- <img src="{:url('Qrcode/qrcode',['code'=>$code1,'type'=>1])}" style="width: 100%" alt="">-->
  193. <!-- <div class="text-center" style="font-weight: bold;font-size: 20px;">调度扫一扫</div>-->
  194. <!-- </div>-->
  195. <!-- <div class="col-xs-2" >-->
  196. <!-- <img src="{:url('Qrcode/qrcode',['code'=>$code,'type'=>1])}" style="width: 100%" alt="">-->
  197. <!-- <div class="text-center" style="font-weight: bold;font-size: 20px;">客户扫一扫</div>-->
  198. <!-- </div>-->
  199. <!-- </div>-->
  200. <!--</div>-->
  201. <div class="panel panel-default">
  202. <div class="panel-body">
  203. <div class="main">
  204. <span class="main-title">订单金额总览</span>
  205. <div class="month">
  206. <select name="month" onchange="loadOrder(this,1)">
  207. {foreach $month as $k=>$v}
  208. <option value="{$v}" {if $v==$curMonth} selected {/if}>{$v}</option>
  209. {/foreach}
  210. </select>
  211. </div>
  212. </div>
  213. <div class="col-xs-3" >
  214. <div class="money">
  215. <div class="money-img">
  216. <img src="/admin/img/m1.png" alt="">
  217. <div class="money-title">订单总金额</div>
  218. </div>
  219. <div class="money-num" id="money-num1">{$orderData.total}</div>
  220. </div>
  221. </div>
  222. <div class="col-xs-3" >
  223. <div class="money">
  224. <div class="money-img">
  225. <img src="/admin/img/m2.png" alt="">
  226. <div class="money-title">预收金</div>
  227. </div>
  228. <div class="money-num" id="money-num2">{$orderData.pre_money}</div>
  229. </div>
  230. </div>
  231. <div class="col-xs-3" >
  232. <div class="money">
  233. <div class="money-img">
  234. <img src="/admin/img/m3.png" alt="">
  235. <div class="money-title">已支付金额</div>
  236. </div>
  237. <div class="money-num" id="money-num3">{$orderData.pay}</div>
  238. </div>
  239. </div>
  240. <div class="col-xs-3" >
  241. <div class="money">
  242. <div class="money-img">
  243. <img src="/admin/img/m4.png" alt="">
  244. <div class="money-title" >已结算金额</div>
  245. </div>
  246. <div class="money-num" id="money-num4">{$orderData.yjs}</div>
  247. </div>
  248. </div>
  249. </div>
  250. </div>
  251. <div class="row">
  252. <div class="col-xs-8">
  253. <div class="row">
  254. <div class="col-xs-6">
  255. <div class="panel panel-default">
  256. <div class="panel-body">
  257. <div class="main">
  258. <span class="main-title">订单状态概览</span>
  259. </div>
  260. <div class="col-xs-4" style="">
  261. <div id="dfp" class="order-view">
  262. </div>
  263. </div>
  264. <div class="col-xs-4" >
  265. <div id="jxz" class="order-view">
  266. </div>
  267. </div>
  268. <div class="col-xs-4" >
  269. <div id="ywc" class="order-view">
  270. </div>
  271. </div>
  272. <div class="col-xs-4" >
  273. <div id="yzf" class="order-view">
  274. </div>
  275. </div>
  276. <div class="col-xs-4" >
  277. <div id="yjs" class="order-view">
  278. </div>
  279. </div>
  280. </div>
  281. </div>
  282. </div>
  283. <div class="col-xs-6">
  284. <div class="panel panel-default">
  285. <div class="panel-body">
  286. <div class="main">
  287. <span class="main-title">订单增长率</span>
  288. </div>
  289. <div class="col-xs-12" >
  290. <div class="z-line">
  291. <div class="z-line1">
  292. <div class="progress">
  293. <div class="progress-bar progress-cus" role="progressbar" aria-valuenow="100"
  294. aria-valuemin="0" aria-valuemax="100" style="width: {$lastBl};">
  295. <span class="sr-only">100% </span>
  296. </div>
  297. </div>
  298. </div>
  299. <div class="z-line1">
  300. <div class="progress">
  301. <div class="progress-bar" role="progressbar"
  302. aria-valuenow="100" aria-valuemin="0" aria-valuemax="100"
  303. style="width: {$curBl};">
  304. <span class="sr-only">90% </span>
  305. </div>
  306. </div>
  307. </div>
  308. </div>
  309. <div class="line-title">
  310. <span class="line-title1">与上月对比</span>
  311. {if $bl <0}
  312. <span class="line-title2" style="color: red !important;">{$bl}%</span>
  313. {else}
  314. <span class="line-title2">+{$bl}%</span>
  315. {/if}
  316. </div>
  317. <div class="line-desc">
  318. <div class="line-desc1">
  319. <span class="line-desc-nums">
  320. {$lastOrder}
  321. </span>
  322. <div class="line-desc-title">
  323. <div class="line-radio1"></div>
  324. <div class="line-desc-title1">上月订单总量</div>
  325. </div>
  326. </div>
  327. <div class="line-desc1">
  328. <span class="line-desc-nums">
  329. {$curOrder}
  330. </span>
  331. <div class="line-desc-title">
  332. <div class="line-radio2"></div>
  333. <div class="line-desc-title1">本月订单量</div>
  334. </div>
  335. </div>
  336. </div>
  337. </div>
  338. </div>
  339. </div>
  340. </div>
  341. <div class="col-xs-12">
  342. <div class="panel panel-default">
  343. <div class="panel-body">
  344. <div class="main">
  345. <span class="main-title">科室/部门订单类型月分布</span>
  346. <div class="month">
  347. <select name="month" id="" onchange="loadOrder(this,2)">
  348. {foreach $month as $k=>$v}
  349. <option value="{$v}" {if $v==$curMonth} selected {/if}>{$v}</option>
  350. {/foreach}
  351. </select>
  352. </div>
  353. </div>
  354. <div class="col-xs-12" >
  355. <div id="ks-order">
  356. </div>
  357. </div>
  358. </div>
  359. </div>
  360. </div>
  361. </div>
  362. </div>
  363. <div class="col-xs-4">
  364. <div class="panel panel-default">
  365. <div class="panel-body" style="height: 632px">
  366. <div class="main">
  367. <span class="main-title">陪护人员工作数据预览</span>
  368. </div>
  369. <div class="col-xs-4">
  370. <div class="worker">
  371. <div class="worker-num1">
  372. {$userCount.count1}
  373. </div>
  374. <div class="worker-title1">
  375. 陪护总数
  376. </div>
  377. </div>
  378. </div>
  379. <div class="col-xs-4" >
  380. <div class="worker">
  381. <div class="worker-num2">
  382. {$userCount.count2}
  383. </div>
  384. <div class="worker-title1">
  385. 在岗人数
  386. </div>
  387. </div>
  388. </div>
  389. <div class="col-xs-4" >
  390. <div class="worker">
  391. <div class="worker-num3">
  392. {$userCount.count3}
  393. </div>
  394. <div class="worker-title1">
  395. 空闲人数
  396. </div>
  397. </div>
  398. </div>
  399. <table class="table worker-list">
  400. <tr>
  401. <th>姓名</th>
  402. <th>进行中</th>
  403. <th>已完成</th>
  404. <th>服务天数</th>
  405. </tr>
  406. {foreach $workerList as $k=>$v}
  407. <tr>
  408. <td>{$v.name}</td>
  409. <td>{$v.count}</td>
  410. <td>{$v.ywc}</td>
  411. <td>{$v.day}</td>
  412. </tr>
  413. {/foreach}
  414. </table>
  415. </div>
  416. </div>
  417. </div>
  418. </div>
  419. {/block}
  420. {block name="script"}
  421. <script src="/static/echarts.js"></script>
  422. <script>
  423. function loadOrder(obj,type) {
  424. $.post('{:url("view")}',{type:type,'month':obj.value},function (res) {
  425. if(res.code==0){
  426. if(type==1){
  427. $('#money-num1').html(res.data.total)
  428. $('#money-num2').html(res.data.preMoney)
  429. $('#money-num3').html(res.data.pay)
  430. $('#money-num4').html(res.data.yjs)
  431. }else {
  432. option = {
  433. tooltip: {
  434. trigger: 'axis'
  435. },
  436. legend: {
  437. data: res.data.data1
  438. },
  439. grid: {
  440. left: '3%',
  441. right: '4%',
  442. bottom: '3%',
  443. containLabel: true
  444. },
  445. xAxis: {
  446. type: 'category',
  447. boundaryGap: false,
  448. data: res.data.data2
  449. },
  450. yAxis: {
  451. type: 'value'
  452. },
  453. series: res.data.data3
  454. };
  455. var myChart7 = echarts.init(document.getElementById('ks-order'));
  456. myChart7.setOption(option);
  457. }
  458. }else {
  459. layer.msg('加载失败');
  460. }
  461. })
  462. }
  463. $(function () {
  464. option = {
  465. color: ['#FB6666','#FED1D1'],
  466. legend: {
  467. top: '5%',
  468. left: 'center'
  469. },
  470. series: [
  471. {
  472. type: 'pie',
  473. radius: ['55%', '70%'],
  474. avoidLabelOverlap: false,
  475. labelLine: {
  476. show: false
  477. },
  478. data: [
  479. { value: '{$dfp.count1}' },
  480. { value:'{$dfp.count2}' },
  481. ],
  482. label:{
  483. normal:{
  484. show:true,
  485. position:'center',
  486. formatter:function () {
  487. return '{$dfp.bl}\n待分配';
  488. },
  489. textStyle:{
  490. fontSize:10,
  491. color:'#666666'
  492. }
  493. }
  494. }
  495. }
  496. ]
  497. };
  498. var myChart2 = echarts.init(document.getElementById('dfp'));
  499. myChart2.setOption(option);
  500. option = {
  501. color: ['#FDAB29','#FEE6BE'],
  502. legend: {
  503. top: '5%',
  504. left: 'center'
  505. },
  506. series: [
  507. {
  508. type: 'pie',
  509. radius: ['55%', '70%'],
  510. avoidLabelOverlap: false,
  511. labelLine: {
  512. show: false
  513. },
  514. data: [
  515. { value: '{$jxz.count1}' },
  516. { value: '{$jxz.count2}' },
  517. ],
  518. label:{
  519. normal:{
  520. show:true,
  521. position:'center',
  522. formatter:function () {
  523. return '{$jxz.bl}\n进行中';
  524. },
  525. textStyle:{
  526. fontSize:10,
  527. color:'#666666'
  528. }
  529. }
  530. }
  531. }
  532. ]
  533. };
  534. var myChart3 = echarts.init(document.getElementById('jxz'));
  535. myChart3.setOption(option);
  536. option = {
  537. color: ['#7C42FF','#D7C6FF'],
  538. legend: {
  539. top: '5%',
  540. left: 'center'
  541. },
  542. series: [
  543. {
  544. type: 'pie',
  545. radius: ['55%', '70%'],
  546. avoidLabelOverlap: false,
  547. labelLine: {
  548. show: false
  549. },
  550. data: [
  551. { value: '{$ywc.count1}' },
  552. { value:'{$ywc.count2}' },
  553. ],
  554. label:{
  555. normal:{
  556. show:true,
  557. position:'center',
  558. formatter:function () {
  559. return '{$ywc.bl}\n已完成';
  560. },
  561. textStyle:{
  562. fontSize:10,
  563. color:'#666666'
  564. }
  565. }
  566. }
  567. }
  568. ]
  569. };
  570. var myChart4 = echarts.init(document.getElementById('ywc'));
  571. myChart4.setOption(option);
  572. option = {
  573. color: ['#426EFD','#C6D3FE'],
  574. legend: {
  575. top: '5%',
  576. left: 'center'
  577. },
  578. series: [
  579. {
  580. type: 'pie',
  581. radius: ['55%', '70%'],
  582. avoidLabelOverlap: false,
  583. labelLine: {
  584. show: false
  585. },
  586. data: [
  587. { value: '{$yzf.count1}' },
  588. { value:'{$yzf.count2}' },
  589. ],
  590. label:{
  591. normal:{
  592. show:true,
  593. position:'center',
  594. formatter:function () {
  595. return '{$yzf.bl}\n已作废';
  596. },
  597. textStyle:{
  598. fontSize:10,
  599. color:'#666666'
  600. }
  601. }
  602. }
  603. }
  604. ]
  605. };
  606. var myChart5 = echarts.init(document.getElementById('yzf'));
  607. myChart5.setOption(option);
  608. option = {
  609. color: ['#70FAFF','#D4FDFF'],
  610. legend: {
  611. top: '5%',
  612. left: 'center'
  613. },
  614. series: [
  615. {
  616. type: 'pie',
  617. radius: ['55%', '70%'],
  618. avoidLabelOverlap: false,
  619. labelLine: {
  620. show: false
  621. },
  622. data: [
  623. { value: '{$yjs.count1}' },
  624. { value:'{$yjs.count2}' },
  625. ],
  626. label:{
  627. normal:{
  628. show:true,
  629. position:'center',
  630. formatter:function () {
  631. return '{$yjs.bl}\n已结算';
  632. },
  633. textStyle:{
  634. fontSize:10,
  635. color:'#666666'
  636. }
  637. }
  638. }
  639. }
  640. ]
  641. };
  642. var myChart6 = echarts.init(document.getElementById('yjs'));
  643. myChart6.setOption(option);
  644. option = {
  645. tooltip: {
  646. trigger: 'axis'
  647. },
  648. legend: {
  649. data: {:json_encode($viewDataList['data1'])}
  650. },
  651. grid: {
  652. left: '3%',
  653. right: '4%',
  654. bottom: '3%',
  655. containLabel: true
  656. },
  657. xAxis: {
  658. type: 'category',
  659. boundaryGap: false,
  660. data: {:json_encode($viewDataList['data2'])}
  661. },
  662. yAxis: {
  663. type: 'value'
  664. },
  665. series: {:json_encode($viewDataList['data3'])}
  666. };
  667. var myChart7 = echarts.init(document.getElementById('ks-order'));
  668. myChart7.setOption(option);
  669. })
  670. </script>
  671. {/block}