dayinfo.vue 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. <template>
  2. <div class="health-day-info">
  3. <div class="header">
  4. <span class="herder-info" :width="800" v-for="item of gridDatas" :key="item">场站:{{ item.wpid }}</span>
  5. <span class="herder-info">基础指标</span>
  6. </div>
  7. <div class="body">
  8. <div class="left">
  9. <table class="table-form">
  10. <tr>
  11. <td class="white" v-for="item of gridDatas" :key="item">
  12. 等级:{{ item.grade }}
  13. </td>
  14. </tr>
  15. <tr>
  16. <td class="white" v-for="item of gridDatas" :key="item">
  17. 综合排名:{{ item.zpm }}
  18. </td>
  19. </tr>
  20. </table>
  21. <div class="chart-body">
  22. <normal-radar-chart :height="'500px'" :value="chartDatas" />
  23. </div>
  24. </div>
  25. <div class="left">
  26. <table class="table-form">
  27. <tr>
  28. <td class="white">指标</td>
  29. <td class="white" v-for="item of gridDatas" :key="item">
  30. {{ item.wpid }}
  31. </td>
  32. <td class="white" :colspan="gridDatas.length">排名</td>
  33. <td class="white" colspan="2">评分</td>
  34. </tr>
  35. <tr v-for="item of column" :key="item">
  36. <td class="white">{{ item.name }}</td>
  37. <td class="white" v-for="row of gridDatas" :key="row">
  38. {{ row[item.field] }}
  39. </td>
  40. <td class="white" v-for="row of gridDatas" :key="row">
  41. {{ row[item.rank] }}
  42. </td>
  43. <td class="white" v-for="row of gridDatas" :key="row">
  44. {{ row[item.score] ? row[item.score] : 0 }}
  45. </td>
  46. </tr>
  47. </table>
  48. </div>
  49. </div>
  50. </div>
  51. </template>
  52. <script>
  53. import NormalRadarChart from "../../../components/chart/radar/normal-radar-chart.vue";
  54. export default {
  55. components: {
  56. NormalRadarChart
  57. },
  58. props: {
  59. gridDatas: {},
  60. chartDatas: {},
  61. column: []
  62. },
  63. data() {
  64. return {
  65. value: "",
  66. radarValue: [{
  67. indicator: [
  68. "复位及时率(%)", "mttf", "缺陷下单及时率(%)", "缺陷验收及时率(%)", "设备利用小时", "限电损失率(%)", "性能损失率(%)",
  69. "综合场用电量", "状态转换及时率(%)"
  70. ],
  71. data: [{
  72. value: [
  73. 44200, 14200, 20000, 35000, 50000, 38000, 44200, 14200, 20000,
  74. 35000,
  75. ],
  76. name: "NAME1",
  77. },
  78. {
  79. value: [
  80. 35000, 44200, 14200, 20000, 35000, 50000, 38000, 44200, 14200,
  81. 20000,
  82. ],
  83. name: "NAME2",
  84. },
  85. ],
  86. }, ],
  87. };
  88. },
  89. };
  90. </script>
  91. <style lang="less">
  92. .health-day-info {
  93. .header {
  94. display: flex;
  95. width: 100%;
  96. height: 40px;
  97. line-height: 40px;
  98. background: fade(@gray, 60);
  99. color: @white;
  100. .herder-info {
  101. flex: 1 0 25%;
  102. text-align: center;
  103. font-size: @fontsize-s;
  104. &:last-child {
  105. flex: 1 0 50%;
  106. }
  107. }
  108. }
  109. .body {
  110. display: flex;
  111. .left {
  112. flex: 0 0 50%;
  113. display: flex;
  114. flex-direction: column;
  115. .chart-body {
  116. flex-grow: 1;
  117. display: flex;
  118. align-items: center;
  119. }
  120. }
  121. .right {
  122. flex: 0 0 50%;
  123. }
  124. }
  125. }
  126. </style>