Rectification.vue 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. <template>
  2. <div class="rect">
  3. <div class="unit-hid">
  4. <div>隐患数
  5. <span class="num">{{ total.yhzs }}</span>
  6. </div>
  7. <span>单位:个</span>
  8. </div>
  9. <div class="num-hid">
  10. <span>15日到期隐患数
  11. <div class="hid">{{ total.rdq15 }}</div>
  12. </span>
  13. <span>30日到期隐患数
  14. <div class="hid">{{ total.rdq30 }}</div>
  15. </span>
  16. <span>60日到期隐患数
  17. <div class="hid">{{ total.rdq60 }}</div>
  18. </span>
  19. </div>
  20. <!--限期 -->
  21. <div class="hid-img">
  22. <div>
  23. <img src="../../../assets/images/Frame 1296.png" alt="">
  24. <span>限期2023年底整改数量</span>
  25. </div>
  26. <span class="hid-num">{{ total.nzgsl2023 }}</span>
  27. </div>
  28. <div class="hid-img">
  29. <div>
  30. <img src="../../../assets/images/Frame 1296.png" alt="">
  31. <span>限期2024年底整改数量</span>
  32. </div>
  33. <span class="hid-num"> {{ total.nzgsl2024 }}</span>
  34. </div>
  35. <div class="hid-img">
  36. <div>
  37. <img src="../../../assets/images/Frame 1296.png" alt="">
  38. <span>限期2024年底整改数量</span>
  39. </div>
  40. <span class="hid-num">{{ total.nzgsl2025 }}</span>
  41. </div>
  42. </div>
  43. </template>
  44. <script >
  45. import { zgtj } from '@/api/risk'
  46. export default {
  47. name: 'RectificationComp',
  48. props: {
  49. qx: String
  50. },
  51. data() {
  52. return {
  53. total: {
  54. qy: "",
  55. yhzs: 0,
  56. rdq15: 0,
  57. rdq30: 0,
  58. rdq60: 0,
  59. nzgsl2023: 0,
  60. nzgsl2024: 0,
  61. nzgsl2025: 0
  62. }
  63. }
  64. },
  65. watch: {
  66. qx: {
  67. handler() {
  68. this.loadData()
  69. },
  70. immediate: true
  71. }
  72. },
  73. methods: {
  74. loadData() {
  75. zgtj({
  76. pageNum: 1,
  77. pageSize: 1,
  78. qy: this.qx
  79. }).then(res => {
  80. this.total = res.data.rows[0]
  81. })
  82. }
  83. }
  84. }
  85. </script>
  86. <style lang="less" scoped>
  87. .rect{
  88. font-size: 16px;
  89. margin: 10px 10px;
  90. .num{
  91. font-size: 20px;
  92. }
  93. .hid{
  94. font-size: 28px;
  95. color: #FFCB44;
  96. text-align: center;
  97. }
  98. .num-hid{
  99. display: flex;
  100. justify-content: space-between;
  101. justify-items: center;
  102. align-items: center;
  103. }
  104. .unit-hid{
  105. display: flex;
  106. justify-content: space-between;
  107. margin-bottom: 20px;
  108. }
  109. .hid-img{
  110. display: flex;
  111. justify-content: space-between;
  112. align-items: center;
  113. margin-top: 10px;
  114. img{
  115. margin-right: 8px;
  116. }
  117. }
  118. .hid-num{
  119. font-size: 32px;
  120. color: #00C2FF;
  121. }
  122. }
  123. </style>