diff --git a/src/views/user/alteration/Alteration.vue b/src/views/user/alteration/Alteration.vue index 6f410f1..f5f6cfd 100644 --- a/src/views/user/alteration/Alteration.vue +++ b/src/views/user/alteration/Alteration.vue @@ -239,15 +239,21 @@ export default { e.preventDefault() let that = this let phone = that.form.getFieldValue('phone') + let username = that.form.getFieldValue('username') if (!phone) { this.cmsFailed('手机号不能为空!') return } + if (!username) { + this.cmsFailed('用户名不能为空!') + return + } this.form.validateFields(['phone'], { force: true }, (err) => { if (!err) { const hide = this.$message.loading('验证码发送中..', 0) let smsParams = { - phone: phone + phone: phone, + userName: username } getAction('/sys/sendVerificationCode', smsParams).then(res => { if (!res.success) {