|
@@ -1,15 +1,15 @@
|
|
<template>
|
|
<template>
|
|
- <div>
|
|
|
|
- <el-form ref="form" :model="formData" :rules="formRules" label-width="80px" class="form">
|
|
|
|
|
|
+ <div class="page-form-container">
|
|
|
|
+ <el-form ref="form" :model="formData" :rules="formRules" label-width="80px">
|
|
<el-form-item label="原手机号" prop="oldMobile">
|
|
<el-form-item label="原手机号" prop="oldMobile">
|
|
<el-input v-model="formData.oldMobile" placeholder="请输入原手机号" disabled />
|
|
<el-input v-model="formData.oldMobile" placeholder="请输入原手机号" disabled />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
<el-form-item label="验证码" prop="verifyCode">
|
|
<el-form-item label="验证码" prop="verifyCode">
|
|
<el-row>
|
|
<el-row>
|
|
- <el-col :span="17">
|
|
|
|
|
|
+ <el-col :span="18">
|
|
<el-input v-model="formData.verifyCode" placeholder="请输入验证码" />
|
|
<el-input v-model="formData.verifyCode" placeholder="请输入验证码" />
|
|
</el-col>
|
|
</el-col>
|
|
- <el-col :span="7" class="send-code">
|
|
|
|
|
|
+ <el-col :span="6" class="send-code">
|
|
<el-button type="primary" @click="handleSendVerifyCode()">{{ sendCodeBtnText }}</el-button>
|
|
<el-button type="primary" @click="handleSendVerifyCode()">{{ sendCodeBtnText }}</el-button>
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
@@ -18,7 +18,7 @@
|
|
<el-input v-model="formData.newMobile" placeholder="请输入新手机号" />
|
|
<el-input v-model="formData.newMobile" placeholder="请输入新手机号" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-form>
|
|
</el-form>
|
|
- <div class="submit-btn">
|
|
|
|
|
|
+ <div class="control-box">
|
|
<el-button type="primary" @click="submit()">确认</el-button>
|
|
<el-button type="primary" @click="submit()">确认</el-button>
|
|
<el-button type="warning" @click="$_back()">返回</el-button>
|
|
<el-button type="warning" @click="$_back()">返回</el-button>
|
|
</div>
|
|
</div>
|
|
@@ -67,7 +67,7 @@ export default {
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
submit() {
|
|
submit() {
|
|
- this.$refs.form.validate(valide => {
|
|
|
|
|
|
+ this.$refs.form.validate((valide) => {
|
|
if (!valide) return
|
|
if (!valide) return
|
|
this.saveMobile()
|
|
this.saveMobile()
|
|
})
|
|
})
|
|
@@ -75,7 +75,7 @@ export default {
|
|
// 保存
|
|
// 保存
|
|
saveMobile() {
|
|
saveMobile() {
|
|
this.formData.authUserId = this.$store.getters.authUserId
|
|
this.formData.authUserId = this.$store.getters.authUserId
|
|
- resetMobile(this.formData).then(res => {
|
|
|
|
|
|
+ resetMobile(this.formData).then((res) => {
|
|
this.$message.success('修改手机号成功')
|
|
this.$message.success('修改手机号成功')
|
|
this.$store.dispatch('tagsView/delView', this.$route)
|
|
this.$store.dispatch('tagsView/delView', this.$route)
|
|
this.$router.back()
|
|
this.$router.back()
|
|
@@ -87,7 +87,7 @@ export default {
|
|
this.$message.warning('请输入正确的手机号')
|
|
this.$message.warning('请输入正确的手机号')
|
|
return
|
|
return
|
|
}
|
|
}
|
|
- sendVerifyCode({ mobile: this.formData.oldMobile }).then(res => {
|
|
|
|
|
|
+ sendVerifyCode({ mobile: this.formData.oldMobile }).then((res) => {
|
|
this.$message.success('验证码已发送')
|
|
this.$message.success('验证码已发送')
|
|
this.countdown()
|
|
this.countdown()
|
|
})
|
|
})
|
|
@@ -108,17 +108,7 @@ export default {
|
|
</script>
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
<style lang="scss" scoped>
|
|
-.submit-btn {
|
|
|
|
- text-align: center;
|
|
|
|
- .el-button {
|
|
|
|
- width: 140px;
|
|
|
|
- }
|
|
|
|
-}
|
|
|
|
.send-code {
|
|
.send-code {
|
|
text-align: right;
|
|
text-align: right;
|
|
}
|
|
}
|
|
-.form {
|
|
|
|
- width: 600px;
|
|
|
|
- margin: 80px auto 0;
|
|
|
|
-}
|
|
|
|
</style>
|
|
</style>
|