Sfoglia il codice sorgente

根据健康码显示

wgl 4 anni fa
parent
commit
0113e7892b
1 ha cambiato i file con 11 aggiunte e 1 eliminazioni
  1. 11 1
      src/projects/business/views/Common/Health/Cert.vue

+ 11 - 1
src/projects/business/views/Common/Health/Cert.vue

@@ -145,7 +145,9 @@
 						this.maxTemparture = response[0]['temperatureMax'];
 						this.detail.totalDays = response[0]['totalDays'];
 						this.detail.undetectedCount = response[0]['undetectedCount'];
-						this.getStatus()
+						//this.getStatus()
+						//只根据绿码来判断状态
+						this.getGreenCode()
 						this.echarts();
 					}
 
@@ -155,6 +157,14 @@
 					mui.toast(error);
 				})
 			},
+			//根据绿码显示颜色
+			getGreenCode() {
+				var colors = this.$refs.greenCode.getCode();
+				this.statusColor = colors.foreground;
+				this.statusTitleColor = colors.foreground;
+				this.statusName = colors.title;
+				console.log(colors);
+			},
 			//计算显示颜色
 			getStatus() {
 				if (this.chartsList.length) {