code refactor

This commit is contained in:
MaysWind
2021-01-04 23:52:57 +08:00
parent 5077b93105
commit b7589e57f2
20 changed files with 561 additions and 293 deletions
+13
View File
@@ -60,6 +60,19 @@ export default {
}
}
},
created() {
if (this.$user.isUserLogined()) {
if (!this.$settings.isEnableApplicationLock()) {
// refresh token if user is logined
this.$store.dispatch('refreshTokenAndRevokeOldToken');
// auto refresh exchange rates data
if (this.$settings.isAutoUpdateExchangeRatesData()) {
this.$services.autoRefreshLatestExchangeRates();
}
}
}
},
methods: {
isiOSHomeScreenMode() {
if ((/iphone|ipod|ipad/gi).test(navigator.platform) && (/Safari/i).test(navigator.appVersion) &&