| | |
| | | <div class="phoneNum"> |
| | | <el-input |
| | | placeholder="请输入注册手机号" |
| | | v-model="formData.phoneNum" |
| | | v-model.trim="formData.phoneNum" |
| | | class="input-with-select" |
| | | > |
| | | </el-input> |
| | |
| | | </el-form-item> |
| | | |
| | | <el-form-item prop="password"> |
| | | <el-input |
| | | <PwInput |
| | | show-password |
| | | v-model="formData.password" |
| | | placeholder="请设置6-14位登录密码" |
| | | > |
| | | </el-input> |
| | | </PwInput> |
| | | <div class="iconfont"></div> |
| | | </el-form-item> |
| | | |
| | | <el-form-item prop="repassword"> |
| | | <el-input |
| | | <PwInput |
| | | show-password |
| | | v-model="formData.repassword" |
| | | placeholder="确认密码" |
| | | > |
| | | </el-input> |
| | | </PwInput> |
| | | <div class="iconfont"></div> |
| | | </el-form-item> |
| | | |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import { getVerifyCode } from "@/api/login"; |
| | | import { getVerifyCode, forgetPwd } from "@/api/login"; |
| | | import { isPhone, validPassword } from "@/scripts/validate"; // 正则文件 |
| | | |
| | | export default { |
| | |
| | | } |
| | | }); |
| | | }, |
| | | submit() { |
| | | async submit() { |
| | | const res = await forgetPwd({ |
| | | phoneNum: this.formData.phoneNum, |
| | | newPwd: this.formData.password, |
| | | }); |
| | | if (res && res.success) { |
| | | this.$notify({ |
| | | type: "success", |
| | | message: "重置成功", |
| | | }); |
| | | } |
| | | this.isReseted = true; |
| | | }, |
| | | }, |