Skip to content

Commit

Permalink
Formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
s-egge committed Jan 15, 2024
1 parent 2fd2f76 commit 974a178
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
5 changes: 1 addition & 4 deletions src/components/charts/chartController.vue
Original file line number Diff line number Diff line change
Expand Up @@ -364,10 +364,7 @@ export default {
formatMultipleTimePeriods: function (charts) {
// change the labels to match the time period for each chart
for (let chart of charts) {
chart.label =
chart.data[0].x.toDateString() +
' to ' +
chart.data[chart.data.length - 1].x.toDateString()
chart.label = chart.data[0].x.toDateString() + ' to ' + chart.data[chart.data.length - 1].x.toDateString()
}
// find chart with largest dataset
Expand Down
6 changes: 3 additions & 3 deletions src/components/view/modals/edit_card.vue
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@
ref="submeters"
v-model="form.sets[currentIndex].meter"
style="width: 100%"
@change=meterChange(currentIndex)
@change="meterChange(currentIndex)"
>
<el-option v-for="item in meters" :key="item.path" :label="item.name" :value="item.path"></el-option>
</el-select>
Expand Down Expand Up @@ -214,7 +214,7 @@
ref="submeters"
v-model="form.sets[currentIndex].meter"
style="width: 100%"
@change=meterChange(currentIndex)
@change="meterChange(currentIndex)"
>
<el-option v-for="item in meters" :key="item.path" :label="item.name" :value="item.path"></el-option>
</el-select>
Expand Down Expand Up @@ -616,7 +616,7 @@ export default {
})
},
// change measurement selection and update card name based on meter type
meterChange: function(index) {
meterChange: function (index) {
this.form.sets[index].point = this.meterPoints[0].value
let energyType = this.$store.getters[this.form.sets[index].meter + '/meters'][0].type
this.form.name = energyType
Expand Down

0 comments on commit 974a178

Please sign in to comment.