keep the state of selected legend

This commit is contained in:
MaysWind
2024-06-10 23:26:04 +08:00
parent 5107e451d8
commit 5fec41055e
+4 -1
View File
@@ -1,6 +1,6 @@
<template>
<v-chart autoresize class="trends-chart-container" :class="{ 'transition-in': skeleton }" :option="chartOptions"
@click="clickItem" />
@click="clickItem" @legendselectchanged="onLegendSelectChanged" />
</template>
<script>
@@ -322,6 +322,9 @@ export default {
return color;
},
onLegendSelectChanged: function (e) {
this.selectedLegends = e.selected;
},
getDisplayCurrency(value, currencyCode) {
return this.$locale.getDisplayCurrency(value, currencyCode, {
currencyDisplayMode: this.settingsStore.appSettings.currencyDisplayMode,