双宇设置
This commit is contained in:
@@ -292,6 +292,14 @@
|
||||
moment,
|
||||
changeLocale(localeval) {
|
||||
this.isLoading = true
|
||||
switch (localeval) {
|
||||
case 'zh-cn':
|
||||
localStorage.setItem('language', 'zh-cn')
|
||||
break
|
||||
case 'en-us':
|
||||
localStorage.setItem('language', 'en-us')
|
||||
break
|
||||
}
|
||||
store.dispatch('GetPermissionList').then(res => {
|
||||
this.$root.Bus.$emit('switchLanguage', localeval)
|
||||
this.isLoading = false
|
||||
@@ -301,17 +309,11 @@
|
||||
this.$i18n.locale = EN
|
||||
this.locale = enUS
|
||||
this.queryAllDictItemsByCut()
|
||||
this.GetPermissionList()
|
||||
// localStorage.setItem('language', EN)
|
||||
// location.reload();
|
||||
} else {
|
||||
moment.locale(ZH)
|
||||
this.$i18n.locale = ZH
|
||||
this.locale = zhCN
|
||||
this.queryAllDictItemsByCut()
|
||||
this.GetPermissionList()
|
||||
// localStorage.setItem('language', ZH)
|
||||
// location.reload();
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user