🐛 异常处理

This commit is contained in:
ronger 2022-10-28 14:59:01 +08:00
parent a2f72f6d0a
commit 9147962fde
2 changed files with 4 additions and 10 deletions

View File

@ -10,7 +10,7 @@
</el-col>
<el-col :span="24">
<el-link target="_blank" :href="'/user/' + user.account" class="text-default">
<span style="font-size: 20px;font-weight: bold;">{{ user.nickname }}</span>
<span style="font-size: 20px;font-weight: bold;" v-html="user.nickname"></span>
</el-link>
</el-col>
<el-col :span="24" style="padding: 1rem 0;">

View File

@ -83,17 +83,9 @@ export default {
_ts.$refs.user.validate(async (valid) => {
if (valid) {
_ts.$set(_ts, 'loginLoading', true);
setTimeout(function () {
_ts.$set(_ts, 'loginLoading', false);
}, 10000);
let fingerprint = _ts.$store.state.fingerprint;
let data = {
account: _ts.user.account,
password: _ts.user.password,
fingerprint: fingerprint
password: _ts.user.password
}
try {
let response = await _ts.$auth.loginWith('local', {data: data})
@ -107,7 +99,9 @@ export default {
})
}
}
_ts.$set(_ts, 'loginLoading', false);
} catch (err) {
_ts.$set(_ts, 'loginLoading', false);
console.log(err)
}
} else {