Health3.vue 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442
  1. <template>
  2. <div class="health-3">
  3. <div class="power-info mg-b-8">
  4. <div class="info-tab">
  5. <div class="tab active">
  6. <i class="svg-icon svg-icon svg-icon-sm">
  7. <svg-icon :svgid="'svg-wind-site'" />
  8. </i>
  9. <span> 24小时健康趋势 </span>
  10. </div>
  11. <div class="tab">
  12. <i class="svg-icon svg-icon svg-icon-sm">
  13. <svg-icon :svgid="'svg-wind-site'" />
  14. </i>
  15. <span> 7日健康趋势 </span>
  16. </div>
  17. <div class="tab">
  18. <i class="svg-icon svg-icon svg-icon-sm">
  19. <svg-icon :svgid="'svg-wind-site'" />
  20. </i>
  21. <span>30日健康趋势</span>
  22. </div>
  23. <div class="empty"></div>
  24. <div class="tab">
  25. <span>全部风场健康趋势</span>
  26. </div>
  27. </div>
  28. <div class="info-chart">
  29. <panel class="info-chart-panel" :title="'损失电量分析'">
  30. <vertival-bar-line-chart :height="'310px'" />
  31. </panel>
  32. </div>
  33. </div>
  34. <div class="fj-info">
  35. <div class="left-info ">
  36. <panel title="预测电量" class="mg-b-16">
  37. <list-bar-chart :list="listBarData1" :colors="listBarData1Color" :height="'9.5vh'" />
  38. <div class="dashboard">
  39. <dashboard-2 :height="'7.5vh'" :width="'115px'" :value="25" />
  40. <div class="lengends">
  41. <div class="item">
  42. <span class="label">本日预测电量</span>
  43. <span class="lengend gary"></span>
  44. <span class="value">123</span>
  45. </div>
  46. <div class="item">
  47. <span class="label">本日已发电量</span>
  48. <span class="lengend green"></span>
  49. <span class="value">123</span>
  50. </div>
  51. </div>
  52. </div>
  53. <div class="dashboard">
  54. <dashboard-2 :height="'7.5vh'" :width="'115px'" :value="34" />
  55. <div class="lengends">
  56. <div class="item">
  57. <span class="label">本日预测电量</span>
  58. <span class="lengend gary"></span>
  59. <span class="value">123</span>
  60. </div>
  61. <div class="item">
  62. <span class="label">本日已发电量</span>
  63. <span class="lengend green"></span>
  64. <span class="value">123</span>
  65. </div>
  66. </div>
  67. </div>
  68. </panel>
  69. <panel title="设备健康度" class="mg-b-16">
  70. <thermometer-v-chart :height="'5.5vh'" :value="100" />
  71. </panel>
  72. <panel title="隐患等级" class="mg-b-16">
  73. <normal-pie-chart :height="'14vh'" />
  74. </panel>
  75. </div>
  76. <div class="right-info">
  77. <toolbar-panel title="风机健康矩阵列表" :showLine="false" class="matrix-panel mg-b-8">
  78. <template v-slot:tools>
  79. <div class="tools">
  80. <span class="level">
  81. <span class="text green">优</span>:
  82. <span class="value white">98</span>
  83. <span class="unit gray">台</span>
  84. </span>
  85. <span class="level">
  86. <span class="text purple">良</span>:
  87. <span class="value white">98</span>
  88. <span class="unit gray">台</span>
  89. </span>
  90. <span class="level">
  91. <span class="text orange">差</span>:
  92. <span class="value white">98</span>
  93. <span class="unit gray">台</span>
  94. </span>
  95. </div>
  96. </template>
  97. <div class="matrix">
  98. <div class="item green">1号</div>
  99. <div class="item purple">2号</div>
  100. <div class="item orange">3号</div>
  101. <div class="item" v-for="index of 100" :key="index">{{ index + 3 }}号</div>
  102. <div class="blank" v-for="index of 20" :key="index"></div>
  103. </div>
  104. </toolbar-panel>
  105. <div class="table">
  106. <Table :data="tableData" />
  107. </div>
  108. </div>
  109. </div>
  110. </div>
  111. </template>
  112. <script>
  113. import ListBarChart from "../../components/chart/bar/list-bar-chart.vue";
  114. import VertivalBarLineChart from "../../components/chart/combination/vertival-bar-line-chart.vue";
  115. import Dashboard2 from "../../components/chart/other/Dashboard2.vue";
  116. import ThermometerVChart from "../../components/chart/other/thermometer-v-chart.vue";
  117. import NormalPieChart from "../../components/chart/pie/normal-pie-chart.vue";
  118. import SvgIcon from "../../components/coms/icon/svg-icon.vue";
  119. import Panel from "../../components/coms/panel/panel.vue";
  120. import ToolbarPanel from "../../components/coms/panel/toolbar-panel.vue";
  121. import Table from "../../components/coms/table/table.vue";
  122. export default {
  123. setup() {},
  124. components: { SvgIcon, Panel, VertivalBarLineChart, Table, ListBarChart, ThermometerVChart, NormalPieChart, ToolbarPanel, Dashboard2 },
  125. data() {
  126. return {
  127. listBarData1: [
  128. { name: "未来 {c1|15分钟} 预测电量", value: 123.62 },
  129. { name: "未来 {c1|4小时} 预测电量", value: 123.62 },
  130. ],
  131. listBarData1Color: ["purple", "purple"],
  132. tableData: {
  133. column: [
  134. {
  135. name: "",
  136. field: "index",
  137. is_num: false,
  138. is_light: false,
  139. },
  140. {
  141. name: "项目",
  142. field: "name",
  143. is_num: false,
  144. is_light: false,
  145. },
  146. {
  147. name: "项目",
  148. field: "lqf",
  149. is_num: false,
  150. is_light: false,
  151. },
  152. {
  153. name: "项目",
  154. field: "yggl",
  155. is_num: false,
  156. is_light: false,
  157. },
  158. {
  159. name: "项目",
  160. field: "yyy",
  161. is_num: false,
  162. is_light: false,
  163. },
  164. {
  165. name: "项目",
  166. field: "pcspp",
  167. is_num: false,
  168. is_light: false,
  169. },
  170. ],
  171. data: [
  172. {
  173. index: 1,
  174. name: "MG01-01",
  175. lqf: "0.1000",
  176. yggl: "0.1000",
  177. yyy: "0.10",
  178. pcspp: "0.1000",
  179. u1: "0.1000",
  180. u2: "0.1000",
  181. v1: "0.1000",
  182. v2: "0.1000",
  183. w1: "0.1000",
  184. w2: "0.1000",
  185. zca: "0.1000",
  186. zcb: "0.1000",
  187. clx: "0.1000",
  188. clx1: "0.1000",
  189. clx2: "0.1000",
  190. jc: "0.1000",
  191. hh: "0.1000",
  192. hj: "0.1000",
  193. is_light: false,
  194. },
  195. ],
  196. },
  197. };
  198. },
  199. created() {
  200. for (let i = 1; i < 50; i++) {
  201. this.tableData.data.push(JSON.parse(JSON.stringify(this.tableData.data[0])));
  202. this.tableData.data[i].index = i + 1;
  203. }
  204. },
  205. };
  206. </script>
  207. <style lang="less">
  208. .health-3 {
  209. .power-info {
  210. display: flex;
  211. .info-tab {
  212. flex: 0 0 156px;
  213. display: flex;
  214. flex-direction: column;
  215. height: 350px;
  216. margin-right: 1.4815vh;
  217. .tab {
  218. position: relative;
  219. flex: 0 0 auto;
  220. text-align: center;
  221. line-height: 33px;
  222. margin-right: 8px;
  223. color: @gray-l;
  224. font-size: 12px;
  225. background: fade(@gray, 20);
  226. border: 1px solid fade(@gray, 20);
  227. display: flex;
  228. align-items: center;
  229. i {
  230. margin: 0 1.4815vh;
  231. svg use {
  232. fill: @gray-l;
  233. }
  234. }
  235. &:hover,
  236. &.active {
  237. background: fade(@green, 20);
  238. border: 1px solid @green;
  239. color: @green;
  240. cursor: pointer;
  241. i svg use {
  242. fill: @green;
  243. }
  244. }
  245. &.active::after {
  246. box-sizing: content-box;
  247. width: 0px;
  248. height: 0px;
  249. position: absolute;
  250. right: -19px;
  251. padding: 0;
  252. border-bottom: 9px solid @green;
  253. border-top: 9px solid transparent;
  254. border-left: 9px solid transparent;
  255. border-right: 9px solid transparent;
  256. display: block;
  257. content: "";
  258. z-index: 10;
  259. transform: rotate(90deg);
  260. }
  261. &.active::before {
  262. box-sizing: content-box;
  263. width: 0px;
  264. height: 0px;
  265. position: absolute;
  266. right: -17px;
  267. padding: 0;
  268. border-bottom: 9px solid #063319;
  269. border-top: 9px solid transparent;
  270. border-left: 9px solid transparent;
  271. border-right: 9px solid transparent;
  272. display: block;
  273. content: "";
  274. z-index: 12;
  275. transform: rotate(90deg);
  276. }
  277. & + .tab {
  278. margin-top: 0.7407vh;
  279. }
  280. &:last-child {
  281. text-align: center;
  282. justify-content: center;
  283. }
  284. }
  285. .empty {
  286. flex: 1 0 auto;
  287. }
  288. }
  289. .info-chart {
  290. flex: 1 0 auto;
  291. }
  292. }
  293. .fj-info {
  294. display: flex;
  295. .left-info {
  296. flex: 0 0 300px;
  297. padding-right: 16px;
  298. .com-panel .panel-header {
  299. margin-bottom: 0.7407vh;
  300. }
  301. @media screen and (max-height: 1078px) {
  302. .mg-b-16 {
  303. margin-bottom: 0.7407vh;
  304. }
  305. }
  306. @media screen and (min-height: 1078px) and (max-height: 1080px) {
  307. .com-panel .panel-header {
  308. margin-bottom: 1.4815vh;
  309. }
  310. }
  311. .dashboard {
  312. position: relative;
  313. display: flex;
  314. align-items: center;
  315. .lengends {
  316. font-size: 12px;
  317. line-height: 20px;
  318. padding-left: 12px;
  319. .item {
  320. display: flex;
  321. align-items: center;
  322. .label {
  323. margin-right: 8px;
  324. color: @gray;
  325. }
  326. .lengend {
  327. display: inline-block;
  328. width: 6px;
  329. height: 6px;
  330. background: @gray;
  331. border-radius: 50%;
  332. margin-right: 8px;
  333. &.green {
  334. background: @green;
  335. }
  336. }
  337. .value {
  338. color: fade(@white, 75);
  339. }
  340. }
  341. }
  342. }
  343. }
  344. .right-info {
  345. flex: 1;
  346. .matrix-panel {
  347. .panel-title {
  348. flex: 0 0 auto;
  349. }
  350. .tools {
  351. margin-left: 8px;
  352. .level {
  353. padding: 0 16px;
  354. }
  355. }
  356. .matrix {
  357. display: flex;
  358. flex-wrap: wrap;
  359. .item {
  360. flex: 1 0 calc(100% / 20 - 4px);
  361. line-height: 26px;
  362. background: fade(@gray, 20);
  363. color: @gray-l;
  364. font-size: 12px;
  365. margin-bottom: 4px;
  366. text-align: center;
  367. border: 1px solid transparent;
  368. & + .item {
  369. margin-left: 4px;
  370. }
  371. &:nth-child(20n + 1) {
  372. margin-left: 0px;
  373. }
  374. &.green {
  375. color: @green;
  376. background: fade(@green, 20);
  377. border-color: @green;
  378. }
  379. &.purple {
  380. color: @purple;
  381. background: fade(@purple, 20);
  382. border-color: @purple;
  383. }
  384. &.orange {
  385. color: @orange;
  386. background: fade(@orange, 20);
  387. border-color: @orange;
  388. }
  389. }
  390. .blank {
  391. flex: 1 0 calc(100% / 20 - 4px);
  392. margin-left: 4px;
  393. }
  394. }
  395. }
  396. .table {
  397. .com-table thead tr th {
  398. padding: 0.3704vh 0;
  399. }
  400. tbody {
  401. height: 33vh;
  402. }
  403. }
  404. }
  405. }
  406. }
  407. </style>