大空间消毒机
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

826 lines
34 KiB

2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
  1. <template>
  2. <div class="progress_container">
  3. <div class="header_wrap">
  4. <div class="left_time">
  5. <p class="time">
  6. {{
  7. operatorStore.estimatedRemainingTimeS == 0
  8. ? '已结束'
  9. : `${time_To_hhmmss(operatorStore.estimatedRemainingTimeS)}`
  10. }}
  11. </p>
  12. </div>
  13. <svg
  14. xmlns="http://www.w3.org/2000/svg"
  15. xmlns:xlink="http://www.w3.org/1999/xlink"
  16. fill="none"
  17. version="1.1"
  18. width="181"
  19. height="52"
  20. viewBox="0 0 181 52"
  21. >
  22. <g>
  23. <g>
  24. <g>
  25. <path
  26. d="M82.64,13.3438C81.84,15.7875,80.28,18.9925,79.12,21.0362L83.28,22.5987C84.52000000000001,20.6756,86,17.8306,87.28,15.0263L82.64,13.3438ZM62.72,15.4269C64.28,17.7506,65.84,20.8756,66.36,22.8794L70.72,20.8356C70.08,18.7925,68.4,15.8275,66.8,13.6244L62.72,15.4269ZM52,16.1481C54.480000000000004,17.4706,57.56,19.5537,59,21.0762L61.96,17.35C60.4,15.8675,57.24,13.9444,54.8,12.7825L52,16.1481ZM50.12,26.76C52.68,28.08,55.88,30.2,57.32,31.72L60.24,27.96C58.6,26.48,55.36,24.56,52.84,23.36L50.12,26.76ZM51.24,46.76L55.480000000000004,49.84C57.6,45.8,59.84,41.12,61.68,36.84L58.16,33.92C55.96,38.64,53.2,43.68,51.24,46.76ZM68.68,35.08L80.88,35.08L80.88,38.08L68.68,38.08L68.68,35.08ZM68.68,31.04L68.68,28.08L80.88,28.08L80.88,31.04L68.68,31.04ZM72.48,12.4225L72.48,23.64L64,23.64L64,49.9606L68.68,49.9606L68.68,42.12L80.88,42.12L80.88,44.76C80.88,45.28,80.68,45.48,80.03999999999999,45.52C79.44,45.52,77.32,45.52,75.48,45.4C76.12,46.64,76.76,48.64,76.92,49.92C79.96000000000001,49.92,82.08,49.88,83.6,49.12C85.12,48.4,85.56,47.12,85.56,44.84L85.56,23.64L77.32,23.64L77.32,12.4225L72.48,12.4225ZM121.2,33.76L121.08,35.92L114.16,35.92L115.16,35.36C115,34.88,114.64,34.32,114.16,33.76L121.2,33.76ZM100.72,30.32C100.6,32.08,100.44,34,100.24000000000001,35.92L94.28,35.92L94.28,39.44L99.88,39.44C99.6,41.56,99.36,43.52,99.08,45.12L119.96,45.12C119.8,45.6,119.64,45.88,119.48,46.08C119.12,46.52,118.76,46.6,118.08,46.6C117.36,46.64,115.8,46.6,114.08,46.44C114.6,47.36,115.08,48.84,115.12,49.8C117.2,49.8812,119.2,49.9219,120.44,49.72C121.72,49.6,122.8,49.28,123.68,48.2C124.12,47.64,124.52,46.68,124.84,45.12L129.44,45.12L129.44,41.68L125.36,41.68L125.56,39.44L131.72,39.44L131.72,35.92L125.84,35.92L126.04,32.16C126.08,31.6,126.12,30.32,126.12,30.32L100.72,30.32ZM110.08,34.24C110.56,34.72,111,35.32,111.4,35.92L104.96000000000001,35.92L105.16,33.76L111,33.76L110.08,34.24ZM120.84,39.44L120.6,41.68L113.68,41.68L114.96,41C114.76,40.52,114.4,39.96,113.96,39.44L120.84,39.44ZM109.75999999999999,39.88C110.28,40.4,110.8,41.04,111.16,41.68L104.32,41.68L104.6,39.44L110.6,39.44L109.75999999999999,39.88ZM110.52000000000001,12.4262L110.52000000000001,15.36L97.2,15.36L97.2,18.72L110.52000000000001,18.72L110.52000000000001,20.36L99.88,20.36L99.88,23.68L110.52000000000001,23.68L110.52000000000001,25.4L95.36,25.4L95.36,28.88L130.64,28.88L130.64,25.4L115.44,25.4L115.44,23.68L126.64,23.68L126.64,20.36L115.44,20.36L115.44,18.72L129.36,18.72L129.36,15.36L115.44,15.36L115.44,12.4262L110.52000000000001,12.4262ZM154.36,12.4231L154.36,19.4L140.51999999999998,19.4L140.51999999999998,39.6838L145.32,39.6838L145.32,37.48L154.36,37.48L154.36,50.0187L159.44,50.0187L159.44,37.48L168.51999999999998,37.48L168.51999999999998,39.4831L173.56,39.4831L173.56,19.4L159.44,19.4L159.44,12.4231L154.36,12.4231ZM145.32,32.76L145.32,24.12L154.36,24.12L154.36,32.76L145.32,32.76ZM168.51999999999998,32.76L159.44,32.76L159.44,24.12L168.51999999999998,24.12L168.51999999999998,32.76Z"
  27. fill="#17F179"
  28. fill-opacity="1"
  29. />
  30. </g>
  31. <g transform="matrix(0,1,-1,0,52,-22)">
  32. <path
  33. d="M61.3114,50.5847L56.491,45.7322C62.778400000000005,44.923500000000004,67.8084,39.8689,67.8084,33.8033C67.8084,27.9399,63.1976,22.88525,57.1198,21.87432L52.7186,17.62841L54.6048,17.62841C64.24549999999999,17.62841,72,24.9071,72,33.8033C72,39.8689,68.2276,45.3279,62.988,47.9563L62.988,52L61.3114,50.5847ZM56.7006,49.776C56.0719,49.776,55.2335,49.9781,54.3952,49.9781C44.75449,49.9781,37,42.6995,37,33.8033C37,27.7377,40.77246,22.27869,46.01198,19.650280000000002L46.01198,15L48.7365,17.62842L52.9281,21.67213C46.43114,22.27869,41.4012,27.5355,41.4012,33.8033C41.4012,39.8689,46.22156,44.923500000000004,52.509,45.7322L56.7006,49.776Z"
  34. fill="#17F179"
  35. fill-opacity="1"
  36. />
  37. </g>
  38. </g>
  39. </g>
  40. </svg>
  41. <div
  42. class="btn"
  43. v-if="[1, 2].includes(operatorStore.disinfectStatus)"
  44. @click="stopDisinfect"
  45. >
  46. 结束消毒
  47. </div>
  48. <div
  49. class="btn"
  50. v-if="operatorStore.disinfectStatus == 0"
  51. @click="showDetail"
  52. >
  53. 返回
  54. </div>
  55. </div>
  56. <div class="echarts_wrap">
  57. <div class="single_wrap">
  58. <p class="title">设备</p>
  59. <div
  60. class="echarts_box"
  61. id="bin"
  62. v-if="operatorStore.disinfectStatus != 0 || binLocal"
  63. ></div>
  64. </div>
  65. <div class="single_wrap">
  66. <p class="title">环境1</p>
  67. <div
  68. class="echarts_box"
  69. id="envir1"
  70. v-if="operatorStore.disinfectStatus != 0 || envir1Local"
  71. ></div>
  72. </div>
  73. <div class="single_wrap">
  74. <p class="title">环境2</p>
  75. <div
  76. class="echarts_box"
  77. id="envir2"
  78. v-if="operatorStore.disinfectStatus != 0 || envir2Local"
  79. ></div>
  80. </div>
  81. </div>
  82. <div class="detail_wrap">
  83. <div class="tip_info">警报信息</div>
  84. <div class="speed_wrap">
  85. <p class="speed">5000</p>
  86. </div>
  87. <svg
  88. @click="showDetail"
  89. xmlns="http://www.w3.org/2000/svg"
  90. xmlns:xlink="http://www.w3.org/1999/xlink"
  91. fill="none"
  92. version="1.1"
  93. width="222"
  94. height="50"
  95. viewBox="0 0 222 50"
  96. >
  97. <g>
  98. <g>
  99. <rect
  100. x="0"
  101. y="0"
  102. width="222"
  103. height="50"
  104. rx="25"
  105. fill="#06518B"
  106. fill-opacity="1"
  107. />
  108. </g>
  109. <g>
  110. <path
  111. d="M59.16,27.84L66.68,27.84L66.68,29.24L59.16,29.24L59.16,27.84ZM59.16,25.22L66.68,25.22L66.68,26.58L59.16,26.58L59.16,25.22ZM57.28,23.939999999999998L57.28,30.52L68.64,30.52L68.64,23.939999999999998L57.28,23.939999999999998ZM54.36,31.62L54.36,33.3L71.7,33.3L71.7,31.62L54.36,31.62ZM62,15.3325L62,17.740000000000002L54.1,17.740000000000002L54.1,19.4L60.08,19.4C58.42,21.14,55.96,22.68,53.62,23.46C54.02,23.84,54.56,24.52,54.84,24.98C57.5,23.92,60.2,21.96,62,19.68L62,23.32L63.88,23.32L63.88,19.68C65.72,21.9,68.44,23.82,71.12,24.82C71.4,24.34,71.96000000000001,23.64,72.36,23.28C69.94,22.52,67.44,21.08,65.78,19.4L71.92,19.4L71.92,17.740000000000002L63.88,17.740000000000002L63.88,15.3325L62,15.3325ZM81.36,28.06L89.44,28.06L89.44,29.24L81.36,29.24L81.36,28.06ZM81.36,26.82L81.36,25.68L89.44,25.68L89.44,26.82L81.36,26.82ZM81.36,30.48L89.44,30.48L89.44,31.72L81.36,31.72L81.36,30.48ZM90.84,15.455C87.56,16.05844,81.62,16.34,76.72,16.36C76.88,16.740000000000002,77.06,17.380000000000003,77.08,17.8C78.74,17.8,80.52,17.759999999999998,82.32,17.7L81.98,18.86L76.96000000000001,18.86L76.96000000000001,20.32L81.44,20.32C81.28,20.72,81.1,21.119999999999997,80.92,21.52L75.53999999999999,21.52L75.53999999999999,23.060000000000002L80.08,23.060000000000002C78.84,25.08,77.18,26.86,74.98,28.08C75.36,28.46,75.9,29.14,76.16,29.58C77.44,28.82,78.56,27.9,79.53999999999999,26.86L79.53999999999999,33.965599999999995L81.36,33.965599999999995L81.36,33.18L89.44,33.18L89.44,33.965599999999995L91.32,33.965599999999995L91.32,24.22L81.56,24.22C81.8,23.84,82.02,23.46,82.24,23.060000000000002L93.25999999999999,23.060000000000002L93.25999999999999,21.52L83,21.52L83.5,20.32L92.14,20.32L92.14,18.86L84.02,18.86L84.4,17.6C87.22,17.439999999999998,89.92,17.2,92,16.82L90.84,15.455ZM112.86,15.83219C112.42,17.03406,111.56,18.63656,110.9,19.658099999999997L112.53999999999999,20.3191C113.2,19.3375,114.02000000000001,17.895310000000002,114.7,16.53312L112.86,15.83219ZM102.75999999999999,16.67344C103.58,17.83531,104.4,19.4178,104.68,20.4394L106.4,19.6181C106.06,18.596249999999998,105.18,17.07406,104.36,15.972190000000001L102.75999999999999,16.67344ZM97.42,16.833750000000002C98.66,17.49469,100.18,18.536250000000003,100.88,19.2975L102.06,17.83531C101.3,17.09406,99.75999999999999,16.1325,98.52000000000001,15.531559999999999L97.42,16.833750000000002ZM96.47999999999999,22.18C97.74000000000001,22.82,99.3,23.880000000000003,100.03999999999999,24.6L101.18,23.119999999999997C100.4,22.4,98.8,21.439999999999998,97.56,20.84L96.47999999999999,22.18ZM97.08,32.519999999999996L98.72,33.739999999999995C99.78,31.8,100.97999999999999,29.36,101.9,27.22L100.5,26.08C99.44,28.38,98.06,30.98,97.08,32.519999999999996ZM105.2,26.22L112.02000000000001,26.22L112.02000000000001,28.1L105.2,28.1L105.2,26.22ZM105.2,24.6L105.2,22.759999999999998L112.02000000000001,22.759999999999998L112.02000000000001,24.6L105.2,24.6ZM107.72,15.311250000000001L107.72,21L103.34,21L103.34,33.8809L105.2,33.8809L105.2,29.72L112.02000000000001,29.72L112.02000000000001,31.68C112.02000000000001,31.96,111.92,32.04,111.62,32.06C111.3,32.08,110.24000000000001,32.08,109.2,32.019999999999996C109.44,32.519999999999996,109.72,33.32,109.78,33.82C111.3,33.82,112.34,33.8,113,33.5C113.68,33.2,113.86,32.68,113.86,31.7L113.86,21L109.64,21L109.64,15.311250000000001L107.72,15.311250000000001ZM131.66,25.68L131.57999999999998,27.14L127.72,27.14L128.2,26.86C128.06,26.52,127.76,26.08,127.42,25.68L131.66,25.68ZM121.28,24.3L121.02,27.14L117.94,27.14L117.94,28.58L120.84,28.58C120.72,29.66,120.56,30.68,120.42,31.5L131.04000000000002,31.5C130.94,31.9,130.82,32.14,130.7,32.28C130.51999999999998,32.480000000000004,130.34,32.519999999999996,129.98000000000002,32.519999999999996C129.6,32.54,128.72,32.519999999999996,127.76,32.42C127.98,32.8,128.16,33.4,128.18,33.78C129.24,33.8612,130.26,33.8612,130.84,33.8003C131.45999999999998,33.760000000000005,131.95999999999998,33.6,132.34,33.14C132.6,32.84,132.8,32.36,132.95999999999998,31.5L135.18,31.5L135.18,30.1L133.18,30.1L133.34,28.58L136.45999999999998,28.58L136.45999999999998,27.14L133.45999999999998,2
  112. fill="#FFFFFF"
  113. fill-opacity="1"
  114. />
  115. </g>
  116. <g>
  117. <ellipse
  118. cx="25"
  119. cy="25"
  120. rx="19"
  121. ry="19"
  122. fill="#FFFFFF"
  123. fill-opacity="1"
  124. />
  125. </g>
  126. <g>
  127. <path
  128. d="M19.02871,32.7154L26.9271,32.7154C27.2819,32.7154,27.5694,33.003,27.5694,33.3577C27.5694,33.7124,27.2819,34,26.9271,34L19.02878,34C17.35495,34.0013,15.99791543,32.643699999999995,16.00000275899,30.969900000000003L16.00000275899,19.03051C15.99771433,17.35657,17.35476,15.99871462,19.02871,16L30.9681,16C32.6422,15.999239749,33.9994,17.35649,33.998599999999996,19.03051L33.998599999999996,19.03261L33.972,26.9309C33.9678,27.2836,33.6803,27.5672,33.3275,27.5666C32.9747,27.566000000000003,32.688199999999995,27.281599999999997,32.685,26.928800000000003L32.685,26.9267L32.712199999999996,19.02978C32.712,18.56363,32.5319,18.1255,32.2024,17.79601C31.875799999999998,17.46756,31.4313,17.28341,30.9681,17.28457L19.02871,17.28457C18.06486,17.28485,17.28386,18.06666,17.28458,19.03051L17.28458,30.969900000000003C17.2839,31.9336,18.06494,32.7153,19.02871,32.7154ZM30.7872,21.14739C30.787100000000002,21.50206,30.4996,21.79142,30.1449,21.79142L19.85856,21.78772C19.50381,21.78772,19.21634,21.497709999999998,19.21634,21.142960000000002C19.21634,20.788,19.50375,20.50011,19.858629999999998,20.49959L30.145,20.50293C30.4997,20.503,30.787300000000002,20.79272,30.7872,21.14739ZM31.3598,30.4513L33.812200000000004,32.9037C34.0627,33.1546,34.0626,33.561,33.8119,33.8117C33.5612,34.0624,33.1548,34.0626,32.9039,33.8121L30.4514,31.3596C28.1824,32.973600000000005,25.00281,31.7287,24.432969999999997,29.0031C23.86314,26.2775,26.2776,23.86302,29.0032,24.432850000000002C31.7289,25.002679999999998,32.9738,28.1822,31.3598,30.4513ZM24.35822,25.002850000000002C24.35822,25.35758,24.07066,25.645139999999998,23.71593,25.645139999999998L19.85856,25.643909999999998C19.50417,25.643909999999998,19.21688,25.35662,19.21688,25.00224C19.21688,24.64785,19.50417,24.36057,19.85856,24.36057L23.71593,24.36057C24.07066,24.36057,24.35822,24.648130000000002,24.35822,25.002850000000002ZM25.73168,27.5503C25.29392,29.1839,26.5248,30.7881,28.2161,30.7882C28.898699999999998,30.79,29.5536,30.518700000000003,30.0349,30.0348C31.230800000000002,28.839,30.966900000000003,26.8342,29.502299999999998,25.98853C28.037599999999998,25.142879999999998,26.1694,25.91666,25.73168,27.5503ZM19.21681,28.8564C19.21681,28.5018,19.50429,28.2143,19.85892,28.2143L22.43048,28.2155C22.78752,28.2117,23.07899,28.5001,23.07899,28.8572C23.07899,29.2143,22.78752,29.5026,22.43048,29.4989L19.85892,29.4985C19.50429,29.4985,19.21681,29.211,19.21681,28.8564Z"
  129. fill-rule="evenodd"
  130. fill="#06518B"
  131. fill-opacity="1"
  132. />
  133. </g>
  134. </g>
  135. </svg>
  136. </div>
  137. <DisinfectModal
  138. v-if="disinfectWarnVisible"
  139. :hideDisinfectModal="hideDisinfectModal"
  140. />
  141. </div>
  142. </template>
  143. <script setup>
  144. import { useOperatorStore, useWebSocketStore, useEchartsStore } from '@/store'
  145. import { time_To_hhmmss } from '@/utils'
  146. import {
  147. stopDisinfectionJSON,
  148. getStateJSON,
  149. continueDisinfectionJSON,
  150. pauseDisinfectionJSON,
  151. } from '@/mock/command'
  152. import DisinfectModal from 'cpns/dialogs/DisinfectModal'
  153. import { onMounted, onUnmounted, ref, computed, watch } from 'vue'
  154. import * as echarts from 'echarts'
  155. import { storeToRefs } from 'pinia'
  156. const echartsStore = useEchartsStore()
  157. const binLocal = computed(() => {
  158. return echartsStore?.binCharts || localStorage.getItem('bin')
  159. })
  160. const envir1Local = computed(() => {
  161. return echartsStore?.envir1Charts || localStorage.getItem('envir1')
  162. })
  163. const envir2Local = computed(() => {
  164. return echartsStore?.envir2Charts || localStorage.getItem('envir2')
  165. })
  166. const binOption = ref({
  167. tooltip: {
  168. trigger: 'axis',
  169. },
  170. legend: {
  171. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  172. },
  173. grid: {
  174. left: '3%',
  175. right: '4%',
  176. bottom: '3%',
  177. containLabel: true,
  178. },
  179. xAxis: {
  180. type: 'category',
  181. boundaryGap: false,
  182. data: echartsStore.abscissaFormater,
  183. },
  184. yAxis: {
  185. type: 'value',
  186. },
  187. series: [
  188. {
  189. name: '温度',
  190. type: 'line',
  191. stack: 'binTemp',
  192. data: echartsStore.binTemp,
  193. },
  194. {
  195. name: '湿度',
  196. type: 'line',
  197. stack: 'binHumidity',
  198. data: echartsStore.binHumidity,
  199. },
  200. {
  201. name: 'H2O2浓度',
  202. type: 'line',
  203. stack: 'binHP',
  204. data: echartsStore.binHP,
  205. },
  206. {
  207. name: 'H2O2饱和度',
  208. type: 'line',
  209. stack: 'binSaturation',
  210. data: echartsStore.binSaturation,
  211. },
  212. ],
  213. })
  214. const envir1Option = ref({
  215. tooltip: {
  216. trigger: 'axis',
  217. },
  218. legend: {
  219. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  220. },
  221. grid: {
  222. left: '3%',
  223. right: '4%',
  224. bottom: '3%',
  225. containLabel: true,
  226. },
  227. xAxis: {
  228. type: 'category',
  229. boundaryGap: false,
  230. data: echartsStore.abscissaFormater,
  231. },
  232. yAxis: {
  233. type: 'value',
  234. },
  235. series: [
  236. {
  237. name: '温度',
  238. type: 'line',
  239. stack: '1',
  240. data: [],
  241. },
  242. {
  243. name: '湿度',
  244. type: 'line',
  245. stack: '2',
  246. data: [],
  247. },
  248. {
  249. name: 'H2O2浓度',
  250. type: 'line',
  251. stack: '3',
  252. data: [],
  253. },
  254. {
  255. name: 'H2O2饱和度',
  256. type: 'line',
  257. stack: '4',
  258. data: [],
  259. },
  260. ],
  261. })
  262. const envir2Option = ref({
  263. tooltip: {
  264. trigger: 'axis',
  265. },
  266. legend: {
  267. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  268. },
  269. grid: {
  270. left: '3%',
  271. right: '4%',
  272. bottom: '3%',
  273. containLabel: true,
  274. },
  275. xAxis: {
  276. type: 'category',
  277. boundaryGap: false,
  278. data: echartsStore.abscissaFormater,
  279. },
  280. yAxis: {
  281. type: 'value',
  282. },
  283. series: [
  284. {
  285. name: '温度',
  286. type: 'line',
  287. stack: '1',
  288. data: [],
  289. },
  290. {
  291. name: '湿度',
  292. type: 'line',
  293. stack: '2',
  294. data: [],
  295. },
  296. {
  297. name: 'H2O2浓度',
  298. type: 'line',
  299. stack: '3',
  300. data: [],
  301. },
  302. {
  303. name: 'H2O2饱和度',
  304. type: 'line',
  305. stack: '4',
  306. data: [],
  307. },
  308. ],
  309. })
  310. const operatorStore = useOperatorStore()
  311. const webSocketStore = useWebSocketStore()
  312. const props = defineProps({
  313. changeShowOperator: {
  314. type: Function,
  315. },
  316. })
  317. const showDetail = () => {
  318. props.changeShowOperator(true)
  319. }
  320. const timer = ref(null)
  321. const binCharts = ref(null)
  322. const envir1Charts = ref(null)
  323. const envir2Charts = ref(null)
  324. const time1 = ref(null)
  325. const time2 = ref(null)
  326. onMounted(() => {
  327. timer.value = setInterval(() => {
  328. webSocketStore.sendCommandMsg(getStateJSON)
  329. }, 1000)
  330. let a = echarts.getInstanceByDom(document.getElementById('bin'))
  331. if (a == undefined) {
  332. binCharts.value = echarts.init(document.getElementById('bin'))
  333. binCharts.value.setOption(binOption.value)
  334. }
  335. let b = echarts.getInstanceByDom(document.getElementById('envir1'))
  336. if (b == undefined) {
  337. envir1Charts.value = echarts.init(document.getElementById('envir1'))
  338. envir1Charts.value.setOption(envir1Option.value)
  339. }
  340. let c = echarts.getInstanceByDom(document.getElementById('envir2'))
  341. if (c == undefined) {
  342. envir2Charts.value = echarts.init(document.getElementById('envir2'))
  343. envir2Charts.value.setOption(envir2Option.value)
  344. }
  345. time1.value = setInterval(() => {
  346. binCharts.value?.setOption({
  347. tooltip: {
  348. trigger: 'axis',
  349. },
  350. legend: {
  351. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  352. },
  353. grid: {
  354. left: '3%',
  355. right: '4%',
  356. bottom: '3%',
  357. containLabel: true,
  358. },
  359. xAxis: {
  360. type: 'category',
  361. boundaryGap: false,
  362. data: echartsStore.abscissaFormater,
  363. },
  364. yAxis: {
  365. type: 'value',
  366. },
  367. series: [
  368. {
  369. name: '温度',
  370. type: 'line',
  371. stack: 'binTemp',
  372. data: echartsStore.binTemp,
  373. },
  374. {
  375. name: '湿度',
  376. type: 'line',
  377. stack: 'binHumidity',
  378. data: echartsStore.binHumidity,
  379. },
  380. {
  381. name: 'H2O2浓度',
  382. type: 'line',
  383. stack: 'binHP',
  384. data: echartsStore.binHP,
  385. },
  386. {
  387. name: 'H2O2饱和度',
  388. type: 'line',
  389. stack: 'binSaturation',
  390. data: echartsStore.binSaturation,
  391. },
  392. ],
  393. })
  394. envir1Charts.value?.setOption({
  395. tooltip: {
  396. trigger: 'axis',
  397. },
  398. legend: {
  399. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  400. },
  401. grid: {
  402. left: '3%',
  403. right: '4%',
  404. bottom: '3%',
  405. containLabel: true,
  406. },
  407. xAxis: {
  408. type: 'category',
  409. boundaryGap: false,
  410. data: echartsStore.abscissaFormater,
  411. },
  412. yAxis: {
  413. type: 'value',
  414. },
  415. series: [
  416. {
  417. name: '温度',
  418. type: 'line',
  419. stack: '1',
  420. data: [],
  421. },
  422. {
  423. name: '湿度',
  424. type: 'line',
  425. stack: '2',
  426. data: [],
  427. },
  428. {
  429. name: 'H2O2浓度',
  430. type: 'line',
  431. stack: '3',
  432. data: [],
  433. },
  434. {
  435. name: 'H2O2饱和度',
  436. type: 'line',
  437. stack: '4',
  438. data: [],
  439. },
  440. ],
  441. })
  442. envir2Charts.value?.setOption({
  443. tooltip: {
  444. trigger: 'axis',
  445. },
  446. legend: {
  447. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  448. },
  449. grid: {
  450. left: '3%',
  451. right: '4%',
  452. bottom: '3%',
  453. containLabel: true,
  454. },
  455. xAxis: {
  456. type: 'category',
  457. boundaryGap: false,
  458. data: echartsStore.abscissaFormater,
  459. },
  460. yAxis: {
  461. type: 'value',
  462. },
  463. series: [
  464. {
  465. name: '温度',
  466. type: 'line',
  467. stack: '1',
  468. data: [],
  469. },
  470. {
  471. name: '湿度',
  472. type: 'line',
  473. stack: '2',
  474. data: [],
  475. },
  476. {
  477. name: 'H2O2浓度',
  478. type: 'line',
  479. stack: '3',
  480. data: [],
  481. },
  482. {
  483. name: 'H2O2饱和度',
  484. type: 'line',
  485. stack: '4',
  486. data: [],
  487. },
  488. ],
  489. })
  490. }, 1000 * 20)
  491. time1.value = setInterval(() => {
  492. binCharts.value?.setOption({
  493. tooltip: {
  494. trigger: 'axis',
  495. },
  496. legend: {
  497. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  498. },
  499. grid: {
  500. left: '3%',
  501. right: '4%',
  502. bottom: '3%',
  503. containLabel: true,
  504. },
  505. xAxis: {
  506. type: 'category',
  507. boundaryGap: false,
  508. data: echartsStore.abscissaFormater,
  509. },
  510. yAxis: {
  511. type: 'value',
  512. },
  513. series: [
  514. {
  515. name: '温度',
  516. type: 'line',
  517. stack: 'binTemp',
  518. data: echartsStore.binTemp,
  519. },
  520. {
  521. name: '湿度',
  522. type: 'line',
  523. stack: 'binHumidity',
  524. data: echartsStore.binHumidity,
  525. },
  526. {
  527. name: 'H2O2浓度',
  528. type: 'line',
  529. stack: 'binHP',
  530. data: echartsStore.binHP,
  531. },
  532. {
  533. name: 'H2O2饱和度',
  534. type: 'line',
  535. stack: 'binSaturation',
  536. data: echartsStore.binSaturation,
  537. },
  538. ],
  539. })
  540. envir1Charts.value?.setOption({
  541. tooltip: {
  542. trigger: 'axis',
  543. },
  544. legend: {
  545. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  546. },
  547. grid: {
  548. left: '3%',
  549. right: '4%',
  550. bottom: '3%',
  551. containLabel: true,
  552. },
  553. xAxis: {
  554. type: 'category',
  555. boundaryGap: false,
  556. data: echartsStore.abscissaFormater,
  557. },
  558. yAxis: {
  559. type: 'value',
  560. },
  561. series: [
  562. {
  563. name: '温度',
  564. type: 'line',
  565. stack: '1',
  566. data: [],
  567. },
  568. {
  569. name: '湿度',
  570. type: 'line',
  571. stack: '2',
  572. data: [],
  573. },
  574. {
  575. name: 'H2O2浓度',
  576. type: 'line',
  577. stack: '3',
  578. data: [],
  579. },
  580. {
  581. name: 'H2O2饱和度',
  582. type: 'line',
  583. stack: '4',
  584. data: [],
  585. },
  586. ],
  587. })
  588. envir2Charts.value?.setOption({
  589. tooltip: {
  590. trigger: 'axis',
  591. },
  592. legend: {
  593. data: ['温度', '湿度', 'H2O2浓度', 'H2O2饱和度'],
  594. },
  595. grid: {
  596. left: '3%',
  597. right: '4%',
  598. bottom: '3%',
  599. containLabel: true,
  600. },
  601. xAxis: {
  602. type: 'category',
  603. boundaryGap: false,
  604. data: echartsStore.abscissaFormater,
  605. },
  606. yAxis: {
  607. type: 'value',
  608. },
  609. series: [
  610. {
  611. name: '温度',
  612. type: 'line',
  613. stack: '1',
  614. data: [],
  615. },
  616. {
  617. name: '湿度',
  618. type: 'line',
  619. stack: '2',
  620. data: [],
  621. },
  622. {
  623. name: 'H2O2浓度',
  624. type: 'line',
  625. stack: '3',
  626. data: [],
  627. },
  628. {
  629. name: 'H2O2饱和度',
  630. type: 'line',
  631. stack: '4',
  632. data: [],
  633. },
  634. ],
  635. })
  636. }, 1000)
  637. })
  638. // 监听到store中的数据变化动态更改options
  639. onUnmounted(() => {
  640. timer.value = null
  641. time1.value = null
  642. time2.value = null
  643. })
  644. const pauseDisinfect = () => {
  645. if (operatorStore.disinfectStatus == 1) {
  646. webSocketStore.sendCommandMsg(pauseDisinfectionJSON)
  647. }
  648. }
  649. const disinfectWarnVisible = ref(false)
  650. const stopDisinfect = () => {
  651. disinfectWarnVisible.value = true
  652. if ([1, 2].includes(operatorStore.disinfectStatus)) {
  653. webSocketStore.sendCommandMsg(stopDisinfectionJSON)
  654. }
  655. }
  656. const hideDisinfectModal = () => {
  657. disinfectWarnVisible.value = false
  658. }
  659. const continueDisinfect = () => {
  660. if (operatorStore.disinfectStatus == 2) {
  661. webSocketStore.sendCommandMsg(continueDisinfectionJSON)
  662. }
  663. }
  664. </script>
  665. <style lang="scss" scoped>
  666. .progress_container {
  667. margin-bottom: 19px;
  668. height: 580px;
  669. box-sizing: border-box;
  670. background: #ffffff;
  671. border-radius: 16px;
  672. padding-bottom: 30px;
  673. .header_wrap {
  674. display: flex;
  675. align-items: center;
  676. justify-content: space-between;
  677. margin-bottom: 34px;
  678. height: 107px;
  679. box-sizing: border-box;
  680. padding: 13px 36px 13px 20px;
  681. background: #f6f6f6;
  682. border-radius: 16px 16px 0 0;
  683. .left_time {
  684. position: relative;
  685. width: 377px;
  686. height: 61px;
  687. background: url(../assets/img/operator/time.png) no-repeat;
  688. background-size: 100% 100%;
  689. .time {
  690. font-family: Source Han Sans CN;
  691. font-size: 28px;
  692. font-weight: bold;
  693. line-height: normal;
  694. letter-spacing: 0.1em;
  695. color: #ffffff;
  696. position: absolute;
  697. left: 165px;
  698. top: 9px;
  699. width: 178px;
  700. height: 41px;
  701. text-align: center;
  702. }
  703. }
  704. .btn {
  705. padding: 12px 28px;
  706. white-space: nowrap;
  707. box-sizing: border-box;
  708. width: 140px;
  709. height: 50px;
  710. border-radius: 25px;
  711. background: #06518b;
  712. display: flex;
  713. align-items: center;
  714. justify-content: center;
  715. font-family: Source Han Sans CN;
  716. font-size: 20px;
  717. font-weight: 500;
  718. line-height: normal;
  719. letter-spacing: 0.07em;
  720. color: #ffffff;
  721. }
  722. }
  723. .echarts_wrap {
  724. height: 351px;
  725. display: flex;
  726. padding-left: 20px;
  727. align-items: center;
  728. margin-bottom: 19px;
  729. .single_wrap {
  730. flex: 1;
  731. height: 351px;
  732. .title {
  733. margin-left: 28px;
  734. padding: 5px 13px;
  735. margin-bottom: 24px;
  736. font-family: Source Han Sans CN;
  737. font-size: 14px;
  738. font-weight: 500;
  739. line-height: normal;
  740. letter-spacing: 0.1em;
  741. color: #ffffff;
  742. height: 27px;
  743. border-radius: 14px;
  744. opacity: 1;
  745. background: #06518b;
  746. width: 70px;
  747. box-sizing: border-box;
  748. display: flex;
  749. align-items: center;
  750. justify-content: center;
  751. }
  752. .echarts_box {
  753. width: 380px;
  754. height: 308px;
  755. }
  756. }
  757. }
  758. .detail_wrap {
  759. padding-left: 20px;
  760. display: flex;
  761. align-items: center;
  762. padding-right: 16px;
  763. height: 50px;
  764. .tip_info {
  765. padding: 12px 20px;
  766. box-sizing: border-box;
  767. overflow: hidden;
  768. text-overflow: ellipsis;
  769. white-space: nowrap;
  770. width: 550px;
  771. height: 50px;
  772. border-radius: 6px;
  773. opacity: 1;
  774. background: #f6f6f6;
  775. font-family: Source Han Sans CN;
  776. font-size: 18px;
  777. font-weight: bold;
  778. line-height: normal;
  779. letter-spacing: 0.1em;
  780. margin-right: 20px;
  781. color: #fa1c1c;
  782. }
  783. .speed_wrap {
  784. background: url(../assets/img/operator/speed.png) no-repeat;
  785. background-size: 100% 100%;
  786. position: relative;
  787. width: 335px;
  788. height: 41px;
  789. margin-right: 37px;
  790. .speed {
  791. position: absolute;
  792. font-family: Source Han Sans CN;
  793. font-size: 28px;
  794. font-weight: bold;
  795. line-height: normal;
  796. letter-spacing: 0.02em;
  797. color: #17f179;
  798. left: 197px;
  799. bottom: -2px;
  800. width: 68px;
  801. height: 41px;
  802. white-space: nowrap;
  803. text-align: center;
  804. }
  805. }
  806. }
  807. }
  808. </style>