双宇设置

This commit is contained in:
qq787203167
2022-03-03 16:18:57 +08:00
parent ae812d0318
commit da1837552f
3 changed files with 9 additions and 16 deletions
-9
View File
@@ -58,20 +58,11 @@
// 自己配置多语言适配
this.$root.Bus.$on('switchLanguage', value => {
let router_path = this.$route.path
switch (value) {
case 'zh-cn':
localStorage.setItem('language', 'zh-cn')
break
case 'en-us':
localStorage.setItem('language', 'en-us')
break
}
this.isRouterAlive = false //先关闭,
// 刷新页面
this.$nextTick(function() {
this.isRouterAlive = true //再打开
})
// 系统组件适配
let lang = localStorage.language
if (lang == 'zh-cn') {
+8 -6
View File
@@ -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();
}
})
}
@@ -127,7 +127,7 @@
list: '/sys/sysAnnouncementSend/getMyAnnouncementSend',
editCementSend: 'sys/sysAnnouncementSend/editByAnntIdAndUserId',
readAllMsg: 'sys/sysAnnouncementSend/read',
deleteUrl: ''
deleteUrl: 'sys/sysAnnouncementSend/deleteBatch'
},
loading: false,
openPath: '',