fix some settings change in home page does not take effect

This commit is contained in:
MaysWind
2021-01-31 23:09:12 +08:00
parent 989a754fe3
commit 2755f1e42e
+9 -1
View File
@@ -176,7 +176,9 @@ export default {
loading: true,
todayFirstUnixTime: self.$utilities.getTodayFirstUnixTime(),
todayLastUnixTime: self.$utilities.getTodayLastUnixTime(),
showAmountInHomePage: self.$settings.isShowAmountInHomePage()
showAmountInHomePage: self.$settings.isShowAmountInHomePage(),
isEnableThousandsSeparator: self.$settings.isEnableThousandsSeparator(),
currencyDisplayMode: self.$settings.getCurrencyDisplayMode()
};
},
computed: {
@@ -255,6 +257,12 @@ export default {
onPageAfterIn() {
this.showAmountInHomePage = this.$settings.isShowAmountInHomePage();
if (this.isEnableThousandsSeparator !== this.$settings.isEnableThousandsSeparator() || this.currencyDisplayMode !== this.$settings.getCurrencyDisplayMode()) {
this.isEnableThousandsSeparator = this.$settings.isEnableThousandsSeparator();
this.currencyDisplayMode = this.$settings.getCurrencyDisplayMode();
this.$forceUpdate();
}
let dateChanged = false;
if (this.todayFirstUnixTime !== this.$utilities.getTodayFirstUnixTime()) {