Merge remote-tracking branch 'origin/dev-3.1' into dev-3.1.1_theme
# Conflicts: # nezha-fronted/src/components/common/i18n.js # nezha-fronted/src/components/common/pagination.vue # nezha-fronted/src/components/common/searchInput.vue # nezha-fronted/src/components/common/table/settings/endpointTable.vue # nezha-fronted/src/components/page/dashboard/overview/overview2.vue
This commit is contained in:
@@ -127,7 +127,7 @@ export default {
|
||||
license: {
|
||||
warnInfo: '',
|
||||
token: '',
|
||||
valid: false
|
||||
valid: true
|
||||
},
|
||||
uploadFileList: [],
|
||||
uploadFile: { file: '', path: '', uuid: '' },
|
||||
@@ -148,7 +148,7 @@ export default {
|
||||
methods: {
|
||||
...mapActions(['loginSuccess']),
|
||||
login () {
|
||||
if (this.loading || !this.license.valid) {
|
||||
if (this.loading || !this.license.valid || !this.license.token) {
|
||||
return
|
||||
}
|
||||
if (this.validateLogin() && (this.$route.path == '/' || this.$route.path == '/login')) {
|
||||
@@ -214,6 +214,9 @@ export default {
|
||||
localStorage.setItem('nz-username', this.loginData.username)
|
||||
localStorage.setItem('nz-prometheus-federation-enabled', res.data.prometheusFederationEnabled)
|
||||
localStorage.setItem('nz-language', this.lang)
|
||||
res.data.user = {
|
||||
lang: this.lang
|
||||
}
|
||||
this.loginSuccess(res)
|
||||
} else {
|
||||
this.authToken = res.data.authToken
|
||||
|
||||
Reference in New Issue
Block a user