初始化账号时,对于校验码,需要增加提示和校验
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
f101478135
commit
08cde2f22e
|
@ -1,75 +1,36 @@
|
||||||
<template>
|
<template>
|
||||||
<div style="display: flex; justify-content: center">
|
<div style="display: flex; justify-content: center">
|
||||||
<div
|
<div style="
|
||||||
style="
|
|
||||||
width: 600px;
|
width: 600px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
border: 1px solid #e6e6e6;
|
border: 1px solid #e6e6e6;
|
||||||
margin-top: 40px;
|
margin-top: 40px;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
"
|
">
|
||||||
>
|
<div class="trial-myinfo-head" style="font-size: 30px; line-height: 120px">
|
||||||
<div
|
|
||||||
class="trial-myinfo-head"
|
|
||||||
style="font-size: 30px; line-height: 120px"
|
|
||||||
>
|
|
||||||
<!-- 首次登录修改密码 -->
|
<!-- 首次登录修改密码 -->
|
||||||
{{ $t("recompose:title:init") }}
|
{{ $t("recompose:title:init") }}
|
||||||
</div>
|
</div>
|
||||||
<el-form
|
<el-form ref="passwordForm" v-loading="loading" label-position="right" :model="password"
|
||||||
ref="passwordForm"
|
:rules="passwordFormRules" label-width="120px">
|
||||||
v-loading="loading"
|
|
||||||
label-position="right"
|
|
||||||
:model="password"
|
|
||||||
:rules="passwordFormRules"
|
|
||||||
label-width="120px"
|
|
||||||
>
|
|
||||||
<!-- 用户名 -->
|
<!-- 用户名 -->
|
||||||
<el-form-item :label="$t('recompose:form:userName')" prop="NewUserName">
|
<el-form-item :label="$t('recompose:form:userName')" prop="NewUserName">
|
||||||
<el-input v-model="password.NewUserName" />
|
<el-input v-model="password.NewUserName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 旧密码 -->
|
<!-- 旧密码 -->
|
||||||
<el-form-item
|
<el-form-item :label="$t('recompose:form:oldPassword')" prop="OldPassWord">
|
||||||
:label="$t('recompose:form:oldPassword')"
|
<el-input v-model="password.OldPassWord" type="password" show-password auto-complete="new-password" />
|
||||||
prop="OldPassWord"
|
|
||||||
>
|
|
||||||
<el-input
|
|
||||||
v-model="password.OldPassWord"
|
|
||||||
type="password"
|
|
||||||
show-password
|
|
||||||
auto-complete="new-password"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 新密码 -->
|
<!-- 新密码 -->
|
||||||
<el-form-item
|
<el-form-item :label="$t('recompose:form:newPassword')" prop="NewPassWord">
|
||||||
:label="$t('recompose:form:newPassword')"
|
<el-input v-model="password.NewPassWord" type="password" show-password auto-complete="new-password" />
|
||||||
prop="NewPassWord"
|
|
||||||
>
|
|
||||||
<el-input
|
|
||||||
v-model="password.NewPassWord"
|
|
||||||
type="password"
|
|
||||||
show-password
|
|
||||||
auto-complete="new-password"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 确认密码 -->
|
<!-- 确认密码 -->
|
||||||
<el-form-item
|
<el-form-item :label="$t('recompose:form:confirmPassword')" prop="ConfirmPassWord">
|
||||||
:label="$t('recompose:form:confirmPassword')"
|
<el-input v-model="password.ConfirmPassWord" type="password" show-password auto-complete="new-password" />
|
||||||
prop="ConfirmPassWord"
|
|
||||||
>
|
|
||||||
<el-input
|
|
||||||
v-model="password.ConfirmPassWord"
|
|
||||||
type="password"
|
|
||||||
show-password
|
|
||||||
auto-complete="new-password"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<!-- 检验码 -->
|
<!-- 检验码 -->
|
||||||
<el-form-item
|
<el-form-item :label="$t('trials:researchForm:form:checkCode')" prop="CheckCode" :maxlength="6">
|
||||||
:label="$t('trials:researchForm:form:checkCode')"
|
|
||||||
prop="CheckCode"
|
|
||||||
:maxlength="6"
|
|
||||||
>
|
|
||||||
<el-input v-model="password.CheckCode" type="number" />
|
<el-input v-model="password.CheckCode" type="number" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item style="text-align: right">
|
<el-form-item style="text-align: right">
|
||||||
|
@ -136,6 +97,21 @@ export default {
|
||||||
message: this.$t("recompose:tip:inputCheckCode"),
|
message: this.$t("recompose:tip:inputCheckCode"),
|
||||||
trigger: "blur",
|
trigger: "blur",
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
validator: (rule, value, callback) => {
|
||||||
|
const regex = /^[1-9]\d{5}$/;
|
||||||
|
if (
|
||||||
|
value &&
|
||||||
|
(String(value).includes('.') ||
|
||||||
|
!regex.test(String(value)))
|
||||||
|
) {
|
||||||
|
callback(new Error(this.$t('recompose:tip:inputCheckCode')))
|
||||||
|
} else {
|
||||||
|
callback()
|
||||||
|
}
|
||||||
|
},
|
||||||
|
trigger: 'blur',
|
||||||
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
userId: null,
|
userId: null,
|
||||||
|
@ -207,12 +183,14 @@ export default {
|
||||||
.reset-wrapper {
|
.reset-wrapper {
|
||||||
padding: 20px;
|
padding: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.reset-wrapper .el-page-header {
|
.reset-wrapper .el-page-header {
|
||||||
line-height: 50px;
|
line-height: 50px;
|
||||||
border: 1px solid #ebeef5;
|
border: 1px solid #ebeef5;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.reset-wrapper .box-wrapper {
|
.reset-wrapper .box-wrapper {
|
||||||
width: 60%;
|
width: 60%;
|
||||||
margin: 20px auto;
|
margin: 20px auto;
|
||||||
|
@ -224,6 +202,7 @@ export default {
|
||||||
.is-error {
|
.is-error {
|
||||||
margin-bottom: 40px;
|
margin-bottom: 40px;
|
||||||
}
|
}
|
||||||
|
|
||||||
input:-webkit-autofill {
|
input:-webkit-autofill {
|
||||||
-webkit-text-fill-color: #ededed !important;
|
-webkit-text-fill-color: #ededed !important;
|
||||||
box-shadow: 0 0 0px 1000px transparent inset !important;
|
box-shadow: 0 0 0px 1000px transparent inset !important;
|
||||||
|
@ -231,6 +210,7 @@ input:-webkit-autofill {
|
||||||
background-image: none;
|
background-image: none;
|
||||||
transition: background-color 50000s ease-in-out 0s;
|
transition: background-color 50000s ease-in-out 0s;
|
||||||
}
|
}
|
||||||
|
|
||||||
input {
|
input {
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
caret-color: #fff;
|
caret-color: #fff;
|
||||||
|
|
Loading…
Reference in New Issue