forked from mt-fe-group/mt-yd-ui
update 对dialog进行改版之前
This commit is contained in:
@@ -101,14 +101,20 @@ export default {
|
||||
this.$http
|
||||
.post(this.$http.adornUrl('/login'), this.dataForm)
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 200) {
|
||||
if (res.code !== 0) {
|
||||
// this.getCaptcha()
|
||||
return this.$message.error(res.msg)
|
||||
}
|
||||
Cookies.set('token', res.data.token)
|
||||
this.$router.replace({ name: 'home' })
|
||||
})
|
||||
.catch(() => {})
|
||||
.catch((err) => {
|
||||
this.$message({
|
||||
message: err.message,
|
||||
type: 'error',
|
||||
duration: 2000
|
||||
})
|
||||
})
|
||||
})
|
||||
},
|
||||
1000,
|
||||
|
||||
Reference in New Issue
Block a user