@@ -1076,50 +1076,28 @@ export default {
1076
1076
},
1077
1077
1078
1078
fuelTechGroupName (val ) {
1079
- console .log (' fuelTechGroupName' , val)
1080
-
1081
1079
if (this .isTypeGrowthStackedArea ) {
1082
- this .growthDataset = this .zoomExtent .length > 0 ? this .getGrowthDataset ().filter ((d ) => {
1083
- return d .date >= this .zoomExtent [0 ] && d .date < this .zoomExtent [1 ]
1084
- }) : this .getGrowthDataset ()
1085
-
1086
- console .log (' growthDataset fuelTechGroupName' , this .growthDataset )
1080
+ this .updateGrowDataset ()
1087
1081
}
1088
1082
},
1089
1083
1090
1084
interval () {
1091
1085
this .handleTypeClick ()
1092
1086
1093
1087
if (this .isTypeGrowthStackedArea ) {
1094
- this .growthDataset = this .zoomExtent .length > 0 ? this .getGrowthDataset ().filter ((d ) => {
1095
- return d .date >= this .zoomExtent [0 ] && d .date < this .zoomExtent [1 ]
1096
- }) : this .getGrowthDataset ()
1097
-
1098
- console .log (' growthDataset zoomExtent' , this .growthDataset )
1088
+ this .updateGrowDataset ()
1099
1089
}
1100
1090
},
1101
1091
1102
- // zoomExtent(val) {
1103
- // console.log('zoomExtent', val, this.stackedAreaDataset)
1104
-
1105
- // if (this.isTypeGrowthStackedArea) {
1106
- // this.growthDataset = val.length > 0 ? this.getGrowthDataset().filter((d) => {
1107
- // return d.date >= val[0] && d.date < val[1]
1108
- // }) : this.getGrowthDataset()
1109
-
1110
- // console.log('growthDataset zoomExtent', this.growthDataset)
1111
- // }
1112
- // },
1113
-
1114
1092
isTypeGrowthStackedArea (val ) {
1115
- console .log (' isTypeGrowthStackedArea' , val)
1116
-
1117
1093
if (val) {
1118
- this .growthDataset = this . zoomExtent . length > 0 ? this . getGrowthDataset (). filter (( d ) => {
1119
- return d . date >= this . zoomExtent [ 0 ] && d . date < this . zoomExtent [ 1 ]
1120
- }) : this . getGrowthDataset ()
1094
+ this .updateGrowDataset ()
1095
+ }
1096
+ },
1121
1097
1122
- console .log (' growthDataset isTypeGrowthStackedArea' , this .growthDataset )
1098
+ hiddenDomains () {
1099
+ if (this .isTypeGrowthStackedArea ) {
1100
+ this .updateGrowDataset ()
1123
1101
}
1124
1102
}
1125
1103
},
@@ -1128,11 +1106,7 @@ export default {
1128
1106
this .visHeight = this .chartHeight
1129
1107
1130
1108
if (this .isTypeGrowthStackedArea ) {
1131
- this .growthDataset = this .zoomExtent .length > 0 ? this .getGrowthDataset ().filter ((d ) => {
1132
- return d .date >= this .zoomExtent [0 ] && d .date < this .zoomExtent [1 ]
1133
- }) : this .getGrowthDataset ()
1134
-
1135
- console .log (' growthDataset powerEnergyDataset' , this .growthDataset )
1109
+ this .updateGrowDataset ()
1136
1110
}
1137
1111
},
1138
1112
@@ -1146,6 +1120,12 @@ export default {
1146
1120
doUpdateTickFormats: ' visInteract/doUpdateTickFormats'
1147
1121
}),
1148
1122
1123
+ updateGrowDataset () {
1124
+ this .growthDataset = this .zoomExtent .length > 0 ? this .getGrowthDataset ().filter ((d ) => {
1125
+ return d .date >= this .zoomExtent [0 ] && d .date < this .zoomExtent [1 ]
1126
+ }) : this .getGrowthDataset ()
1127
+ },
1128
+
1149
1129
convertValue (value ) {
1150
1130
return SI .convertValue (
1151
1131
this .chartUnitPrefix ,
0 commit comments