解决注册租户会出现重复信息的bug
This commit is contained in:
@@ -215,6 +215,8 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
handleSubmit() {
|
handleSubmit() {
|
||||||
|
let that = this
|
||||||
|
that.registerBtn = true;
|
||||||
this.form.validateFields((err, values) => {
|
this.form.validateFields((err, values) => {
|
||||||
if (!err) {
|
if (!err) {
|
||||||
if(values.inputCode === this.randCode) {
|
if(values.inputCode === this.randCode) {
|
||||||
@@ -242,7 +244,10 @@
|
|||||||
description: res.data.message || "注册失败",
|
description: res.data.message || "注册失败",
|
||||||
duration: 2
|
duration: 2
|
||||||
});
|
});
|
||||||
|
that.registerBtn = false
|
||||||
}
|
}
|
||||||
|
}).catch((err) => {
|
||||||
|
that.requestFailed(err);
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
this.$notification['error']({
|
this.$notification['error']({
|
||||||
@@ -250,18 +255,13 @@
|
|||||||
description: "验证码错误",
|
description: "验证码错误",
|
||||||
duration: 2
|
duration: 2
|
||||||
});
|
});
|
||||||
|
that.registerBtn = false
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
that.registerBtn = false
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
registerFailed(message) {
|
|
||||||
this.$notification['error']({
|
|
||||||
message: "注册失败",
|
|
||||||
description: message,
|
|
||||||
duration: 2,
|
|
||||||
});
|
|
||||||
|
|
||||||
},
|
|
||||||
requestFailed(err) {
|
requestFailed(err) {
|
||||||
this.$notification['error']({
|
this.$notification['error']({
|
||||||
message: '错误',
|
message: '错误',
|
||||||
|
|||||||
Reference in New Issue
Block a user