-
+
@@ -23,23 +20,52 @@ export default {
type: Number,
default: 0,
},
- total: {
+ target: {
type: Number,
default: 0,
},
+ goodNumber: {
+ type: Number,
+ default:0
+ },
+ componentYield: {
+ type: Number,
+ default:0
+ },
+ period: {
+ type: String,
+ default:'日',
+ },
title: {
type: String,
default: "",
},
+ city: {
+ type: String,
+ default:""
+ }
},
data() {
- return {};
+ return {
+ number: 0,
+ titleYear:'',
+ };
},
computed: {
dataRate() {
- return this.total == 0
+ if ((this.period === '年' || this.period === '月') && this.target != 0) {
+ // console.log(this.componentYield)
+ this.titleYear = this.title + ' ' + `${(this.target * 100).toFixed(0)}%`
+ } else {
+ this.titleYear = this.title
+ }
+ this.number = this.value == 0
? "-"
- : `${(parseFloat(this.value / this.total) * 100).toFixed(0)}%`;
+ : `${(this.value * 100).toFixed(0)}%`
+ // console.log(this.period)
+ return this.value == 0
+ ? "-"
+ : this.value >1 ? 100 + '%' :`${(this.value * 100).toFixed(0)}%`
},
},
methods: {},
@@ -69,7 +95,7 @@ export default {
color: #fff;
position: absolute;
bottom: -200%;
- right: 0;
+ right: 10px;
font-size: 12px;
}
diff --git a/src/views/copilot/efficiency/components/sub/std/StdRateItem.vue b/src/views/copilot/efficiency/components/sub/std/StdRateItem.vue
index ae1dbba..1ea1543 100644
--- a/src/views/copilot/efficiency/components/sub/std/StdRateItem.vue
+++ b/src/views/copilot/efficiency/components/sub/std/StdRateItem.vue
@@ -1,7 +1,7 @@
@@ -10,29 +10,29 @@
diff --git a/src/views/copilot/energy/components/ElecCost.vue b/src/views/copilot/energy/components/ElecCost.vue
index b6c7a17..7a12fa6 100644
--- a/src/views/copilot/energy/components/ElecCost.vue
+++ b/src/views/copilot/energy/components/ElecCost.vue
@@ -1,4 +1,4 @@
-