|
|
@@ -185,6 +185,7 @@ import Cookies from 'js-cookie'
|
|
|
return {
|
|
|
iHeight: '',
|
|
|
iTop: '',
|
|
|
+ loginLoading: false,
|
|
|
imgList: [
|
|
|
{ url: require('../assets/img/lunbo_1.jpg') },
|
|
|
{ url: require('../assets/img/GF002.png') },
|
|
|
@@ -395,6 +396,7 @@ import Cookies from 'js-cookie'
|
|
|
username: this.model.username,
|
|
|
password: this.model.password
|
|
|
}
|
|
|
+ this.loading = true
|
|
|
api
|
|
|
.rtxLogin(params, this.$axios)
|
|
|
.then(res => {
|
|
|
@@ -411,12 +413,14 @@ import Cookies from 'js-cookie'
|
|
|
}
|
|
|
this.identifyCode = ''
|
|
|
this.makeCode(this.identifyCodes, 4)
|
|
|
+ this.loading = false
|
|
|
})
|
|
|
.catch(err => {
|
|
|
this.$message.warning('账号或密码错误')
|
|
|
console.error(err)
|
|
|
this.identifyCode = ''
|
|
|
this.makeCode(this.identifyCodes, 4)
|
|
|
+ this.loading = false
|
|
|
})
|
|
|
}
|
|
|
}
|
|
|
@@ -434,7 +438,7 @@ export default class Login extends Vue {
|
|
|
)
|
|
|
return false
|
|
|
}
|
|
|
- this.logging = true
|
|
|
+ this.loading = true
|
|
|
this.$refs.user.validate(async valid => {
|
|
|
try {
|
|
|
if (valid) {
|
|
|
@@ -472,7 +476,7 @@ export default class Login extends Vue {
|
|
|
this.identifyCode = ''
|
|
|
this.makeCode(this.identifyCodes, 4)
|
|
|
} finally {
|
|
|
- this.logging = false
|
|
|
+ this.loading = false
|
|
|
}
|
|
|
})
|
|
|
}
|