Merge pull request #59 from Undertone0809/chart-show-patch

fix: chart data will not displayed when first enter
This commit is contained in:
ronger 2022-11-01 07:27:38 +08:00 committed by GitHub
commit 2878d8eeee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 3 deletions

View File

@ -593,8 +593,11 @@ export default {
}, },
mounted() { mounted() {
this.$store.commit("setActiveMenu", "admin-dashboard"); this.$store.commit("setActiveMenu", "admin-dashboard");
this.initLastThirtyDaysCharts(this.lastThirtyDays) setTimeout(() => {
this.initHistoryCharts(this.history) this.initLastThirtyDaysCharts(this.lastThirtyDays)
this.initHistoryCharts(this.history)
}, 500);
} }
} }
</script> </script>

View File

@ -155,7 +155,9 @@ export default {
}, },
mounted() { mounted() {
this.$store.commit("setActiveMenu", "open-data"); this.$store.commit("setActiveMenu", "open-data");
this.initLastThirtyDaysCharts(this.lastThirtyDays) setTimeout(() => {
this.initLastThirtyDaysCharts(this.lastThirtyDays)
}, 500);
} }
} }
</script> </script>