HomePage.vue 32 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275
  1. <template>
  2. <Layout>
  3. <template #left>
  4. <div class="left">
  5. <div class="left-top">
  6. <template
  7. v-for="(item, index) in leftContent.topCount"
  8. :key="index"
  9. >
  10. <div>
  11. <template
  12. v-for="(it, id) in item"
  13. :key="id"
  14. >
  15. <div>
  16. <Icon
  17. :name="it.icon"
  18. :size="96"
  19. style="margin-right: 20px;"
  20. />
  21. <div>
  22. <p>
  23. <span>{{ it.num }}</span>
  24. {{ it.until }}
  25. </p>
  26. <p>{{ it.name }}</p>
  27. </div>
  28. </div>
  29. </template>
  30. </div>
  31. </template>
  32. </div>
  33. <div class="left-content">
  34. <template
  35. v-for="(item, index) in leftContent.charts"
  36. :key="index"
  37. >
  38. <Box
  39. :width="655"
  40. :height="455"
  41. :name="item.name"
  42. >
  43. <div
  44. v-if="index === 0"
  45. class="dateChange"
  46. >
  47. <div
  48. v-for="(itm, index) in item.btns"
  49. :key="index"
  50. :class="{ active: index === item.checkId }"
  51. @click="changeFn(index, item)"
  52. >
  53. {{ itm }}
  54. </div>
  55. </div>
  56. <Echart :option="item.option" />
  57. </Box>
  58. </template>
  59. </div>
  60. </div>
  61. </template>
  62. <template #center>
  63. <div>111111</div>
  64. </template>
  65. <template #right>
  66. <div class="right">
  67. <template
  68. v-for="(itemd, indexd) in rightContent"
  69. :key="indexd"
  70. >
  71. <Box
  72. :width="655"
  73. :height="622"
  74. :name="itemd.name"
  75. >
  76. <div
  77. v-if="indexd === 0"
  78. class="statistics"
  79. >
  80. <div class="statistics-top">
  81. <template
  82. v-for="(item, index) in itemd.content[0]"
  83. :key="index"
  84. >
  85. <div>
  86. <p>{{ item.num }}</p>
  87. <p>{{ item.name }}</p>
  88. </div>
  89. </template>
  90. </div>
  91. <div class="statistics-content">
  92. <template
  93. v-for="(item, ids) in itemd.content[1]"
  94. :key="ids"
  95. >
  96. <div>
  97. <Icon
  98. :name="item.icon"
  99. :size="74"
  100. />
  101. <div>
  102. <p>
  103. {{ item.name }}
  104. </p>
  105. <p>
  106. <span>{{ item.num }}</span>
  107. </p>
  108. </div>
  109. </div>
  110. </template>
  111. </div>
  112. </div>
  113. <div
  114. v-else
  115. class="classes"
  116. >
  117. <div
  118. v-if="indexd === 1"
  119. class="classes-top"
  120. >
  121. <template
  122. v-for="(item, id) in itemd.content[0]"
  123. :key="id"
  124. >
  125. <div>
  126. <Icon
  127. :name="item.icon"
  128. :size="74"
  129. />
  130. <div>
  131. <p>
  132. {{ item.name }}
  133. </p>
  134. <p>
  135. <span>{{ item.num }}</span>
  136. {{ item.util }}
  137. </p>
  138. </div>
  139. </div>
  140. </template>
  141. </div>
  142. <div
  143. v-else-if="indexd === 2"
  144. class="classes-top"
  145. >
  146. <template
  147. v-for="(item, id) in itemd.content[0]"
  148. :key="id"
  149. >
  150. <div>
  151. <n-progress
  152. type="circle"
  153. :percentage="item.num"
  154. :offset-degree="180"
  155. :color="item.color"
  156. :indicator-text-color="item.color"
  157. />
  158. <div>
  159. <p>
  160. {{ item.name }}
  161. </p>
  162. <p>
  163. <span>{{ item.num }}</span>
  164. {{ item.util }}
  165. </p>
  166. </div>
  167. </div>
  168. </template>
  169. </div>
  170. <div
  171. v-else
  172. class="classes-top"
  173. >
  174. <template
  175. v-for="(item, id) in itemd.content[0]"
  176. :key="id"
  177. >
  178. <div :style="`justify-content:${id !== 0 ? 'flex-start' : 'center'};`">
  179. <Icon
  180. v-if="id === 0"
  181. :name="item.icon"
  182. :size="74"
  183. />
  184. <n-progress
  185. v-else
  186. type="circle"
  187. :percentage="item.num"
  188. :offset-degree="180"
  189. :color="item.color"
  190. :indicator-text-color="item.color"
  191. />
  192. <div>
  193. <p>
  194. {{ item.name }}
  195. </p>
  196. <p>
  197. <span>{{ item.num }}</span>
  198. {{ item.util }}
  199. </p>
  200. </div>
  201. </div>
  202. </template>
  203. </div>
  204. <div
  205. v-if="indexd === 1 || indexd === 3"
  206. class="classes-scroll"
  207. >
  208. <div class="classes-scroll-head">
  209. <span>线路名称</span>
  210. <span v-if="indexd === 1">
  211. 班次
  212. <i>已发数/准点数</i>
  213. </span>
  214. <span v-else>
  215. 发车
  216. <i>已发数/准点数</i>
  217. </span>
  218. </div>
  219. <div class="scrollBox">
  220. <TankSeamlessScroll
  221. :step-length="60"
  222. :debug="false"
  223. :reverse="false"
  224. >
  225. <template
  226. v-for="(item, index) in itemd.content[1]"
  227. :key="index"
  228. >
  229. <div class="classes-scroll-content">
  230. <div>
  231. <div>
  232. <span>{{ item.name }}<i>{{ item.num }}</i></span>
  233. <span>始</span>
  234. <span>{{ item.start }}</span>
  235. <span>终</span>
  236. <span>{{ item.end }}</span>
  237. </div>
  238. <div>{{ item.plan }}/{{ item.pratic }}</div>
  239. </div>
  240. <div>
  241. <n-progress
  242. type="line"
  243. :percentage="item.pratic"
  244. :show-indicator="false"
  245. processing
  246. />
  247. </div>
  248. </div>
  249. </template>
  250. </TankSeamlessScroll>
  251. </div>
  252. </div>
  253. <template v-else>
  254. <div
  255. v-for="(item, index) in itemd.content[1]"
  256. :key="index"
  257. class="classes-tables"
  258. >
  259. <div class="classes-tables-head">
  260. <span
  261. v-for="(itm, id) in item.head"
  262. :key="id"
  263. >{{ itm }}</span>
  264. </div>
  265. <div class="classes-tables-body">
  266. <div
  267. v-for="(it, ids) in item.body"
  268. :key="ids"
  269. >
  270. <span
  271. v-for="(t, d) in it"
  272. :key="d"
  273. >{{ t }}</span>
  274. </div>
  275. </div>
  276. </div>
  277. </template>
  278. </div>
  279. </Box>
  280. </template>
  281. </div>
  282. </template>
  283. </Layout>
  284. </template>
  285. <script setup lang='ts'>
  286. import Layout from '@/components/layout.vue'
  287. import { ref } from 'vue'
  288. import Box from '@/components/box.vue'
  289. import TankSeamlessScroll from 'tank-vue3-seamless-scroll'
  290. import { graphic } from 'echarts'
  291. import Echart from '@/components/chart.vue'
  292. const datas = [
  293. {
  294. value: 99,
  295. name: '系列一'
  296. },
  297. {
  298. value: 97,
  299. name: '系列二'
  300. },
  301. {
  302. value: 94,
  303. name: '系列三'
  304. },
  305. {
  306. value: 90,
  307. name: '系列四'
  308. },
  309. {
  310. value: 88,
  311. name: '系列五'
  312. },
  313. {
  314. value: 84,
  315. name: '系列6'
  316. },
  317. {
  318. value: 81,
  319. name: '系列7'
  320. },
  321. {
  322. value: 79,
  323. name: '系列8'
  324. },
  325. {
  326. value: 75,
  327. name: '系列9'
  328. },
  329. {
  330. value: 65.88,
  331. name: '系列a'
  332. }
  333. ]
  334. const leftContent = ref({
  335. topCount: [
  336. [
  337. {
  338. num: 6.8, icon: '11', name: '总刷卡量', until: '亿人次'
  339. },
  340. {
  341. num: 6.8, icon: '12', name: '总客流量', until: '亿人次'
  342. },
  343. {
  344. num: 6.8, icon: '13', name: '安全行驶', until: '万公里'
  345. }
  346. ],
  347. [
  348. {
  349. num: 6.8, icon: '14', name: '累计减少碳排放', until: '吨'
  350. },
  351. {
  352. num: 6.8, icon: '15', name: '累计责任事故率', until: '起/百万公里'
  353. },
  354. {
  355. num: 6.8, icon: '16', name: '乘客满意度', until: '%'
  356. }
  357. ]
  358. ],
  359. charts: [
  360. {
  361. name: '客运量',
  362. option: {
  363. grid: {
  364. containLabel: true,
  365. top: 100,
  366. bottom: 100
  367. },
  368. tooltip: {
  369. trigger: 'axis',
  370. axisPointer: {
  371. type: 'shadow'
  372. }
  373. },
  374. legend: {
  375. top: 45,
  376. lett: 'center',
  377. itemGap: 30,
  378. textStyle: {
  379. fontSize: 18,
  380. color: '#C9D2FA'
  381. }
  382. },
  383. xAxis: {
  384. triggerEvent: true,
  385. data: [
  386. '1月',
  387. '2月',
  388. '3月',
  389. '4月',
  390. '5月',
  391. '6月'
  392. ],
  393. axisLabel: {
  394. interval: 0,
  395. fontSize: 18,
  396. color: '#C9D2FA'
  397. }
  398. },
  399. yAxis: [
  400. {
  401. splitNumber: 2,
  402. axisLabel: {
  403. fontSize: 18,
  404. color: '#C9D2FA'
  405. },
  406. splitLine: {
  407. lineStyle: {
  408. type: 'dashed',
  409. color: '#3E4A82'
  410. }
  411. }
  412. },
  413. {
  414. splitNumber: 2,
  415. position: 'right', // 放在右边
  416. axisLabel: {
  417. fontSize: 18,
  418. color: '#C9D2FA',
  419. formatter(value: number) {
  420. // 在标签后面添加百分号
  421. return `${value}%`
  422. }
  423. },
  424. splitLine: {
  425. lineStyle: {
  426. type: 'dashed',
  427. color: '#3E4A82'
  428. }
  429. }
  430. }
  431. ],
  432. series: [
  433. {
  434. name: '客运量',
  435. type: 'bar',
  436. silent: true,
  437. itemStyle: {
  438. color: '#2F8FFF'
  439. },
  440. barWidth: 30,
  441. data: [ 200, 108, 200, 40, 210, 100 ]
  442. },
  443. {
  444. name: '同比增长率',
  445. type: 'line',
  446. yAxisIndex: 1, // 与第二个 y 轴关联
  447. itemStyle: {
  448. color: 'yellow' // 设置折线颜色为黄色
  449. },
  450. data: [ 100, 80, 120, 60, 90, 70 ] // 折线图的数据
  451. }
  452. ]
  453. },
  454. btns: [ '总', '年', '月', '日' ],
  455. checkId: 0
  456. },
  457. {
  458. name: '消费占比',
  459. option: {
  460. title: {
  461. text: '跳槽率19.5%', // 图标内容文本
  462. left: 'center', // 图标内容水平居中
  463. top: 'center', // 图标内容垂直居中
  464. // 文本样式
  465. textStyle: {
  466. color: '#fff', // 图标内容文字颜色
  467. fontSize: '18px', // 图标内容文字大小
  468. fontWeight: 'normal'
  469. }
  470. },
  471. grid: {
  472. containLabel: true
  473. },
  474. // 图表图例
  475. legend: {
  476. type: 'scroll',
  477. orient: 'horizontal', // 图例排列方向
  478. icon: 'circle', // 图例样式为圆形
  479. itemWidth: 10, // 图例图形的宽度
  480. itemHeight: 16, // 图例图形的高度
  481. itemGap: 10, // 图例项之间的间隔
  482. left: 'center', // 图例距离容器右侧的距离
  483. bottom: 0, // 图例垂直居中
  484. textStyle: {
  485. color: 'white', // 图例文字颜色
  486. fontSize: 20
  487. }
  488. },
  489. series: [
  490. {
  491. type: 'pie', // 图表类型为饼图
  492. radius: [ '55%', '75%' ], // 控制内外圆环的半径,30%代表内圆,60%代表外圆
  493. avoidLabelOverlap: true, // 是否启用防止标签重叠策略
  494. showEmptyCircle: true, // 是否在无数据的时候显示一个占位圆
  495. label: {
  496. formatter: '{b}\n{d}%',
  497. color: 'white'
  498. },
  499. data: [
  500. { key: 2, name: '0次', value: 30619 },
  501. { key: 2, name: '1次', value: 5921 },
  502. { key: 2, name: '2次', value: 1153 },
  503. { key: 2, name: '3次', value: 266 },
  504. { key: 2, name: '大于3次', value: 87 },
  505. { key: 2, name: '大于4次', value: 999 },
  506. { key: 2, name: '12次', value: 5921 },
  507. { key: 2, name: '22次', value: 1153 },
  508. { key: 2, name: '32次', value: 266 },
  509. { key: 2, name: '大于32次', value: 87 },
  510. { key: 2, name: '大于42次', value: 999 }
  511. ]
  512. }
  513. ]
  514. }
  515. },
  516. {
  517. name: '客流排名',
  518. option: {
  519. tooltip: {
  520. trigger: 'axis',
  521. axisPointer: {
  522. type: 'shadow'
  523. }
  524. },
  525. grid: {
  526. top: 20,
  527. left: 20,
  528. bottom: 20,
  529. right: 20,
  530. containLabel: true
  531. },
  532. xAxis: {
  533. type: 'value',
  534. splitLine: {
  535. lineStyle: {
  536. color: '#fff'
  537. }
  538. },
  539. axisLabel: {
  540. color: '#fff',
  541. fontSize: 18
  542. }
  543. },
  544. yAxis: {
  545. type: 'category',
  546. inverse: true,
  547. axisTick: {
  548. alignWithLabel: true,
  549. lineStyle: {
  550. color: '#fff'
  551. }
  552. },
  553. axisLine: {
  554. lineStyle: {
  555. color: '#fff'
  556. }
  557. },
  558. data: [ '雨城区', '雨城区', '雨城区', '雨城区', '雨城区', '雨城区', '雨城区', '雨城区' ],
  559. axisLabel: {
  560. fontSize: 18,
  561. color: '#fff',
  562. margin: 10,
  563. rich: {
  564. a1: {
  565. backgroundColor: '#FFFF0050',
  566. width: 30,
  567. height: 28,
  568. align: 'center',
  569. borderRadius: 15,
  570. fontSize: 18,
  571. borderColor: '#FFFF00',
  572. borderType: 'solid',
  573. borderWidth: 1,
  574. padding: [ 2, 0, 0, 0 ]
  575. },
  576. a2: {
  577. backgroundColor: '#F2F2F250',
  578. width: 30,
  579. height: 28,
  580. align: 'center',
  581. borderRadius: 15,
  582. fontSize: 18,
  583. borderColor: '#F2F2F2',
  584. borderType: 'solid',
  585. borderWidth: 1,
  586. padding: [ 2, 0, 0, 0 ]
  587. },
  588. a3: {
  589. backgroundColor: '#FAAD0E50',
  590. width: 30,
  591. height: 28,
  592. align: 'center',
  593. borderRadius: 15,
  594. fontSize: 18,
  595. borderColor: '#FAAD0E',
  596. borderType: 'solid',
  597. borderWidth: 1,
  598. padding: [ 2, 0, 0, 0 ]
  599. },
  600. b: {
  601. backgroundColor: '#00FFFF50',
  602. width: 30,
  603. height: 28,
  604. align: 'center',
  605. borderRadius: 15,
  606. fontSize: 18,
  607. borderColor: '#00FFFF',
  608. borderType: 'solid',
  609. borderWidth: 1,
  610. padding: [ 2, 0, 0, 0 ]
  611. }
  612. },
  613. formatter: (params: string, _id: number) => {
  614. const id = _id + 1
  615. if (_id < 3) {
  616. return `{a${id}|${id}} ${params}`
  617. }
  618. return `{b|${id}} ${params}`
  619. }
  620. }
  621. },
  622. series: [
  623. {
  624. z: 2,
  625. name: 'value',
  626. type: 'bar',
  627. barWidth: 25,
  628. zlevel: 1,
  629. data: datas.map((item, i) => ({
  630. value: item.value,
  631. itemStyle: {
  632. color: new graphic.LinearGradient(0, 0, 1, 0, [
  633. {
  634. offset: 0,
  635. color: 'rgba(24, 103, 222, 0.4)'
  636. },
  637. {
  638. offset: 1,
  639. color: 'rgba(231, 185, 44, 1)'
  640. }
  641. ])
  642. }
  643. })),
  644. label: {
  645. position: 'inside',
  646. color: '#fff',
  647. fontSize: 16
  648. },
  649. itemStyle: {
  650. borderRadius: [ 0, 15, 15, 0 ]
  651. }
  652. }
  653. ]
  654. }
  655. },
  656. {
  657. name: '线路客流排名',
  658. option: {
  659. tooltip: {
  660. trigger: 'axis',
  661. axisPointer: {
  662. type: 'shadow'
  663. }
  664. },
  665. grid: {
  666. top: 20,
  667. left: 20,
  668. bottom: 20,
  669. right: 20,
  670. containLabel: true
  671. },
  672. xAxis: {
  673. type: 'value',
  674. splitLine: {
  675. lineStyle: {
  676. color: '#fff'
  677. }
  678. },
  679. axisLabel: {
  680. color: '#fff',
  681. fontSize: 18
  682. }
  683. },
  684. yAxis: {
  685. type: 'category',
  686. inverse: true,
  687. axisTick: {
  688. alignWithLabel: true,
  689. lineStyle: {
  690. color: '#fff'
  691. }
  692. },
  693. axisLine: {
  694. lineStyle: {
  695. color: '#fff'
  696. }
  697. },
  698. data: [ '1路(45689)', '2路(45689)', '3路(45689)', '4路(45689)', '5路(45689)', '6路(45689)', '7路(45689)', '8路(45689)' ],
  699. axisLabel: {
  700. fontSize: 18,
  701. color: '#fff',
  702. margin: 20,
  703. rich: {
  704. a1: {
  705. backgroundColor: '#FFFF0050',
  706. width: 30,
  707. height: 28,
  708. align: 'center',
  709. borderRadius: 15,
  710. fontSize: 18,
  711. borderColor: '#FFFF00',
  712. borderType: 'solid',
  713. borderWidth: 1,
  714. padding: [ 2, 0, 0, 0 ]
  715. },
  716. a2: {
  717. backgroundColor: '#F2F2F250',
  718. width: 30,
  719. height: 28,
  720. align: 'center',
  721. borderRadius: 15,
  722. fontSize: 18,
  723. borderColor: '#F2F2F2',
  724. borderType: 'solid',
  725. borderWidth: 1,
  726. padding: [ 2, 0, 0, 0 ]
  727. },
  728. a3: {
  729. backgroundColor: '#FAAD0E50',
  730. width: 30,
  731. height: 28,
  732. align: 'center',
  733. borderRadius: 15,
  734. fontSize: 18,
  735. borderColor: '#FAAD0E',
  736. borderType: 'solid',
  737. borderWidth: 1,
  738. padding: [ 2, 0, 0, 0 ]
  739. },
  740. b: {
  741. backgroundColor: '#00FFFF50',
  742. width: 30,
  743. height: 28,
  744. align: 'center',
  745. borderRadius: 15,
  746. fontSize: 18,
  747. borderColor: '#00FFFF',
  748. borderType: 'solid',
  749. borderWidth: 1,
  750. padding: [ 2, 0, 0, 0 ]
  751. }
  752. },
  753. formatter: (params: string, _id: number) => {
  754. const id = _id + 1
  755. if (_id < 3) {
  756. return `{a${id}|${id}} ${params}`
  757. }
  758. return `{b|${id}} ${params}`
  759. }
  760. }
  761. },
  762. series: [
  763. {
  764. z: 2,
  765. name: 'value',
  766. type: 'bar',
  767. barWidth: 25,
  768. zlevel: 1,
  769. data: datas.map((item, i) => ({
  770. value: item.value,
  771. itemStyle: {
  772. color: new graphic.LinearGradient(0, 0, 1, 0, [
  773. {
  774. offset: 0,
  775. color: 'rgba(24, 103, 222, 0.4)'
  776. },
  777. {
  778. offset: 1,
  779. color: 'rgba(231, 185, 44, 1)'
  780. }
  781. ])
  782. }
  783. })),
  784. label: {
  785. position: 'inside',
  786. color: '#fff',
  787. fontSize: 16
  788. },
  789. itemStyle: {
  790. borderRadius: [ 0, 15, 15, 0 ]
  791. }
  792. }
  793. ]
  794. }
  795. }
  796. ]
  797. })
  798. const rightContent = ref([
  799. {
  800. name: '舆情统计',
  801. content: [
  802. [
  803. { name: '报警总数', num: 0 },
  804. { name: '报警企业', num: 0 },
  805. { name: '待反馈', num: 0 },
  806. { name: '待解除', num: 0 }
  807. ],
  808. [
  809. { name: '事件', num: 0, icon: '17' },
  810. { name: '舆情', num: 0, icon: '18' },
  811. { name: '高风险', num: 0, icon: '19' },
  812. { name: '汛情', num: 0, icon: '20' },
  813. { name: '网络检查', num: 0, icon: '21' },
  814. { name: '火险', num: 0, icon: '22' },
  815. { name: '驾驶员报警', num: 0, icon: '23' },
  816. { name: '充电', num: 0, icon: '24' },
  817. { name: '电池高温', num: 0, icon: '25' }
  818. ]
  819. ]
  820. },
  821. {
  822. name: '班次完成率',
  823. content: [
  824. [
  825. {
  826. name: '昨日总班次', num: 100, icon: '26', util: '次'
  827. },
  828. {
  829. name: '昨日完成率', num: 100, icon: '27', util: '%'
  830. }
  831. ],
  832. [
  833. {
  834. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  835. },
  836. {
  837. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  838. },
  839. {
  840. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  841. },
  842. {
  843. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  844. },
  845. {
  846. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  847. }
  848. ]
  849. ]
  850. },
  851. {
  852. name: '班次准点率',
  853. content: [
  854. [
  855. {
  856. name: '昨日首末班准点率', num: 70, icon: '26', util: '%', color: '#00FFFF'
  857. },
  858. {
  859. name: '昨日中途站准点率', num: 70, icon: '29', util: '%', color: '#FAAD0E'
  860. }
  861. ],
  862. [
  863. {
  864. head: [ '今日首班', '方向', '计划', '实际', '状态' ],
  865. body: [
  866. [ '2路(45567)', '下行', '07:00', '8:00', '1' ],
  867. [ '2路(45567)', '下行', '07:00', '8:00', '1' ],
  868. [ '2路(45567)', '下行', '07:00', '8:00', '1' ]
  869. ]
  870. },
  871. {
  872. head: [ '昨日末班', '方向', '计划', '实际', '状态' ],
  873. body: [
  874. [ '2路(45567)', '下行', '07:00', '8:00', '1' ],
  875. [ '2路(45567)', '下行', '07:00', '8:00', '1' ],
  876. [ '2路(45567)', '下行', '07:00', '8:00', '1' ]
  877. ]
  878. }
  879. ]
  880. ]
  881. },
  882. {
  883. name: '发车准点率',
  884. content: [
  885. [
  886. {
  887. name: '昨日准点班次数', num: 70, icon: '26', util: '次', color: '#04FF77'
  888. },
  889. {
  890. name: '昨日准点率', num: 70, icon: '29', util: '%', color: '#04FF77'
  891. }
  892. ],
  893. [
  894. {
  895. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  896. },
  897. {
  898. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  899. },
  900. {
  901. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  902. },
  903. {
  904. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  905. },
  906. {
  907. name: '1路', num: '(45567)', start: '始发站牌名称', end: '始发站牌名称', plan: 100, pratic: 70
  908. }
  909. ]
  910. ]
  911. }
  912. ] as any)
  913. function changeFn(id: number, item: any) {
  914. item.checkId = id
  915. }
  916. </script>
  917. <style lang="scss" scoped>
  918. .left {
  919. padding-right: 40px;
  920. &-top {
  921. &>div {
  922. display: flex;
  923. }
  924. &>div:first-child,
  925. &>div:nth-child(2) {
  926. background: linear-gradient(180deg, rgba(33, 133, 232, 0.0902) 0%, rgba(0, 170, 255, 0) 99%);
  927. &>div {
  928. display: flex;
  929. color: white;
  930. text-shadow: 1px 1px 5px rgba(0, 255, 255, 0.647058823529412);
  931. width: 440px;
  932. height: 160px;
  933. align-items: center;
  934. justify-content: center;
  935. &>div {
  936. &>p:first-child {
  937. font-size: 18px;
  938. span {
  939. font-size: 50px;
  940. }
  941. }
  942. &>p:last-child {
  943. font-size: 24px;
  944. }
  945. }
  946. }
  947. }
  948. }
  949. &-content {
  950. display: flex;
  951. justify-content: space-between;
  952. flex-wrap: wrap;
  953. :deep(.box-content) {
  954. position: relative;
  955. .dateChange {
  956. position: absolute;
  957. width: 360px;
  958. height: 30px;
  959. border-radius: 30px;
  960. border: solid 1px #2185E8;
  961. left: 50%;
  962. transform: translate(-50%, 0);
  963. top: 10px;
  964. z-index: 2;
  965. display: flex;
  966. &>div {
  967. width: 90px;
  968. color: white;
  969. font-size: 16px;
  970. text-align: center;
  971. cursor: pointer;
  972. line-height: 30px;
  973. &:not(:first-child) {
  974. border-left: solid 1px #2185E8;
  975. }
  976. }
  977. .active {
  978. background: #2185e860;
  979. }
  980. }
  981. }
  982. }
  983. }
  984. .right {
  985. display: flex;
  986. justify-content: space-between;
  987. flex-wrap: wrap;
  988. padding-left: 40px;
  989. white-space: nowrap;
  990. text-shadow: 1px 1px 5px rgba(0, 255, 255, 0.647058823529412);
  991. .statistics {
  992. padding: 20px;
  993. &-top {
  994. display: flex;
  995. justify-content: space-between;
  996. &>div {
  997. width: 145px;
  998. height: 145px;
  999. font-size: 20px;
  1000. color: #80FFFF;
  1001. text-align: center;
  1002. background: rgba(33, 133, 232, 0.098);
  1003. border: 1px solid rgba(0, 255, 255, 0.298);
  1004. &>p:first-child {
  1005. padding-top: 33px;
  1006. padding-bottom: 10px;
  1007. font-weight: 700;
  1008. font-style: normal;
  1009. font-size: 40px;
  1010. color: #FFFFFF;
  1011. text-align: center;
  1012. }
  1013. &>p:last-child {
  1014. font-size: 20px;
  1015. }
  1016. }
  1017. }
  1018. &-content {
  1019. display: flex;
  1020. flex-wrap: wrap;
  1021. justify-content: space-between;
  1022. &>div {
  1023. display: flex;
  1024. width: 205px;
  1025. overflow: hidden;
  1026. margin-top: 40px;
  1027. &>div {
  1028. width: 100px;
  1029. color: white;
  1030. padding-left: 20px;
  1031. &>p {
  1032. font-size: 20px;
  1033. span {
  1034. font-size: 34px;
  1035. font-weight: 400;
  1036. }
  1037. }
  1038. }
  1039. }
  1040. }
  1041. }
  1042. .classes {
  1043. padding: 20px;
  1044. &-top {
  1045. display: flex;
  1046. justify-content: space-between;
  1047. &>div {
  1048. width: 300px;
  1049. height: 150px;
  1050. font-size: 20px;
  1051. color: #80FFFF;
  1052. text-align: center;
  1053. background: rgba(33, 133, 232, 0.098);
  1054. border: 1px solid rgba(0, 255, 255, 0.298);
  1055. display: flex;
  1056. align-items: center;
  1057. justify-content: center;
  1058. &>div {
  1059. // padding-left: 20px;
  1060. margin-left: 10px;
  1061. text-align: left;
  1062. &:first-child {
  1063. width: 99px;
  1064. height: 99px;
  1065. }
  1066. &>p:last-child {
  1067. color: white;
  1068. font-family: 'Impact Normal', 'Impact', sans-serif;
  1069. &>span {
  1070. font-size: 34px;
  1071. font-weight: 400;
  1072. margin-right: 5px;
  1073. }
  1074. }
  1075. }
  1076. }
  1077. }
  1078. &-scroll {
  1079. &-head {
  1080. margin-top: 40px;
  1081. margin-bottom: 20px;
  1082. display: flex;
  1083. justify-content: space-between;
  1084. font-size: 20px;
  1085. color: #80FFFF;
  1086. &>span:last-child {
  1087. color: white;
  1088. i {
  1089. color: #80FFFF;
  1090. }
  1091. }
  1092. }
  1093. &-content {
  1094. font-family: Arial Normal;
  1095. &>div:first-child {
  1096. display: flex;
  1097. justify-content: space-between;
  1098. align-items: center;
  1099. &>div:first-child {
  1100. display: flex;
  1101. font-size: 18px;
  1102. align-items: flex-end;
  1103. text-shadow: none;
  1104. &>span {
  1105. &:first-child {
  1106. width: 153px;
  1107. height: 48px;
  1108. border-radius: 5px;
  1109. background: rgba(33, 133, 232, 0.298);
  1110. border: 3px solid #80FFFF;
  1111. font-size: 24px;
  1112. color: white;
  1113. text-align: center;
  1114. line-height: 40px;
  1115. overflow: hidden;
  1116. margin-right: 10px;
  1117. i {
  1118. font-size: 20px;
  1119. margin-left: 10px;
  1120. }
  1121. }
  1122. &:nth-child(4),
  1123. &:nth-child(2) {
  1124. width: 30px;
  1125. height: 30px;
  1126. color: #FFFFFF;
  1127. border-radius: 50%;
  1128. border: 1px solid #2bb972;
  1129. background: #2BB97249;
  1130. text-align: center;
  1131. line-height: 30px;
  1132. margin: 0 5px;
  1133. }
  1134. &:nth-child(4) {
  1135. border: 1px solid #E73D41;
  1136. background: #E73D4149;
  1137. margin-left: 10px;
  1138. }
  1139. &:nth-child(3),
  1140. &:last-child {
  1141. color: #81D3F8;
  1142. padding-bottom: 5px;
  1143. }
  1144. }
  1145. }
  1146. &>div:last-child {
  1147. font-size: 24px;
  1148. text-align: right;
  1149. color: #FFFFFF;
  1150. }
  1151. }
  1152. &>div:last-child {
  1153. height: 40px;
  1154. padding: 13px 0;
  1155. }
  1156. }
  1157. }
  1158. .scrollBox {
  1159. height: 270px;
  1160. overflow: hidden;
  1161. }
  1162. &-tables {
  1163. text-shadow: none;
  1164. font-family: 'Arial Normal', 'Arial', sans-serif;
  1165. font-weight: 400;
  1166. text-align: center;
  1167. font-size: 20px;
  1168. color: #FFFFFF;
  1169. &:nth-child(3)>div:nth-child(2)>div:last-child,
  1170. &:nth-child(2)>div:nth-child(2)>div:first-child {
  1171. color: #E73D41;
  1172. }
  1173. &:nth-child(3)>div:first-child>span:first-child {
  1174. color: #FAAD0E;
  1175. }
  1176. &-head {
  1177. display: flex;
  1178. align-items: center;
  1179. background: rgba(86, 137, 240, 0.298);
  1180. height: 40px;
  1181. margin-top: 20px;
  1182. &>span {
  1183. width: 112px;
  1184. font-weight: 700;
  1185. &:first-child {
  1186. width: 182px;
  1187. color: #04FF77;
  1188. }
  1189. }
  1190. }
  1191. &-body {
  1192. color: #81D3F8;
  1193. &>div {
  1194. display: flex;
  1195. align-items: center;
  1196. height: 50px;
  1197. &>span {
  1198. width: 112px;
  1199. &:first-child {
  1200. width: 182px;
  1201. }
  1202. }
  1203. }
  1204. }
  1205. }
  1206. }
  1207. }
  1208. </style>