|
|
@@ -4,60 +4,83 @@
|
|
|
<div class="box">
|
|
|
<div class="name">企业认证 <span>账户实名认证后不能修改</span></div>
|
|
|
<div class="border"></div>
|
|
|
- <div class="fail" v-if="userInfo.authStatus === 'PENDING' || userInfo.authStatus === 'FAIL'">
|
|
|
+ <div
|
|
|
+ class="fail"
|
|
|
+ v-if="
|
|
|
+ userInfo.authStatus === 'PENDING' ||
|
|
|
+ userInfo.authStatus === 'FAIL' ||
|
|
|
+ userInfo.authStatus === 'SUCCESS'
|
|
|
+ "
|
|
|
+ >
|
|
|
<img class="text1" src="../../assets/user/icon-xiugaichengg@3x (1).png" alt="" />
|
|
|
- <div class="text2">已提交企业认证</div>
|
|
|
- <div class="text3">等待后台审核信息,预计1-3个工作日内完成</div>
|
|
|
- <div class="botn" @click="Jump">返回</div>
|
|
|
+ <div class="text2" v-if="userInfo.authStatus === 'PENDING'">已提交企业认证</div>
|
|
|
+ <div class="text2" v-if="userInfo.authStatus === 'FAIL'">认证失败</div>
|
|
|
+ <div class="text2" v-if="userInfo.authStatus === 'SUCCESS'">认证成功</div>
|
|
|
+ <div class="text3" v-if="userInfo.authStatus === 'PENDING'">
|
|
|
+ 等待后台审核信息,预计1-3个工作日内完成
|
|
|
+ </div>
|
|
|
+ <div class="text3" v-if="userInfo.authStatus === 'SUCCESS'">账户实名认证后不能修改</div>
|
|
|
+ <div class="text3" v-if="userInfo.authStatus === 'FAIL'">信息填写有误</div>
|
|
|
+ <div class="botn" v-if="userInfo.authStatus !== 'FAIL'" @click="all('accountdata')">返回</div>
|
|
|
+ <div class="botn" v-if="userInfo.authStatus === 'FAIL'" @click="Jump2">重新认证</div>
|
|
|
</div>
|
|
|
- <div v-if="userInfo.authStatus === 'NOT_AUTH' || userInfo.authStatus === 'SUCCESS'">
|
|
|
+ <div v-if="userInfo.authStatus === 'NOT_AUTH'">
|
|
|
<el-form ref="form" :label-position="labelPosition" :model="sizeForm" :rules="registerRule">
|
|
|
- <el-form-item label="法人姓名" prop="nickname">
|
|
|
+ <el-form-item label="法人姓名" prop="realName">
|
|
|
<el-input
|
|
|
style="width: 300px"
|
|
|
placeholder="请输入您的真实姓名"
|
|
|
- v-model="sizeForm.nickname"
|
|
|
+ v-model="sizeForm.realName"
|
|
|
></el-input>
|
|
|
</el-form-item>
|
|
|
- <el-form-item label="法人身份证号" prop="IDs">
|
|
|
+ <el-form-item label="法人身份证号" prop="idNo">
|
|
|
<el-input
|
|
|
style="width: 300px"
|
|
|
placeholder="请输入18位身份证号"
|
|
|
- v-model="sizeForm.IDs"
|
|
|
+ v-model="sizeForm.idNo"
|
|
|
></el-input>
|
|
|
</el-form-item>
|
|
|
|
|
|
- <el-form-item label="法人身份证 (正面图)" prop="photoFront">
|
|
|
- <single-upload class="upload" v-model="sizeForm.photoFront"></single-upload>
|
|
|
+ <el-form-item label="法人身份证 (正面图)" prop="idFront">
|
|
|
+ <single-upload class="upload" v-model="sizeForm.idFront"></single-upload>
|
|
|
</el-form-item>
|
|
|
<div class="description">{{ explain }}</div>
|
|
|
- <el-form-item label="法人身份证 (反面图)" prop="photoBackside">
|
|
|
- <single-upload class="upload" v-model="sizeForm.photoBackside"></single-upload>
|
|
|
+ <el-form-item label="法人身份证 (反面图)" prop="idBack">
|
|
|
+ <single-upload class="upload" v-model="sizeForm.idBack"></single-upload>
|
|
|
</el-form-item>
|
|
|
<div class="description">{{ explain }}</div>
|
|
|
- <el-form-item label="企业名称" prop="name">
|
|
|
- <el-input style="width: 300px" placeholder="请输入企业名称" v-model="sizeForm.name"></el-input>
|
|
|
- </el-form-item>
|
|
|
- <el-form-item label="工商营业执照注册号/统一社会信用代码" prop="uscc">
|
|
|
+ <el-form-item label="企业名称" prop="orgName">
|
|
|
<el-input
|
|
|
style="width: 300px"
|
|
|
- placeholder="工商营业执照注册号/统一社会信用代码"
|
|
|
- v-model="sizeForm.uscc"
|
|
|
+ placeholder="请输入企业名称"
|
|
|
+ v-model="sizeForm.orgName"
|
|
|
></el-input>
|
|
|
</el-form-item>
|
|
|
- <el-form-item prop="establishedAt" label="工商营业执照有效日期截止时间">
|
|
|
- <el-date-picker
|
|
|
- v-model="sizeForm.establishedAt"
|
|
|
- type="date"
|
|
|
+ <el-form-item label="工商营业执照注册号/统一社会信用代码" prop="orgNo">
|
|
|
+ <el-input
|
|
|
style="width: 300px"
|
|
|
- value-format="yyyy-MM-dd"
|
|
|
- placeholder="选择日期"
|
|
|
- >
|
|
|
- </el-date-picker>
|
|
|
+ placeholder="工商营业执照注册号/统一社会信用代码"
|
|
|
+ v-model="sizeForm.orgNo"
|
|
|
+ ></el-input>
|
|
|
</el-form-item>
|
|
|
+ <div class="content">
|
|
|
+ <el-form-item prop="orgLicenseExpire" label="工商营业执照有效日期截止时间">
|
|
|
+ <el-date-picker
|
|
|
+ v-model="sizeForm.orgLicenseExpire"
|
|
|
+ type="date"
|
|
|
+ style="width: 300px"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ placeholder="选择日期"
|
|
|
+ >
|
|
|
+ </el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
+ <template>
|
|
|
+ <el-radio v-model="sizeForm.radio" label="1">长期</el-radio>
|
|
|
+ </template>
|
|
|
+ </div>
|
|
|
<div class="description">证照有效截止日期需大于60天,如证照上日期为长期或无,请勾选长期</div>
|
|
|
- <el-form-item label="营业执照" prop="businessLicense">
|
|
|
- <single-upload class="upload" v-model="sizeForm.businessLicense"></single-upload>
|
|
|
+ <el-form-item label="营业执照" prop="orgLicense">
|
|
|
+ <single-upload class="upload" v-model="sizeForm.orgLicense"></single-upload>
|
|
|
</el-form-item>
|
|
|
<div class="description">请上传清晰图片,格式JPG或PNG,大小不得超过 2 M</div>
|
|
|
</el-form>
|
|
|
@@ -77,28 +100,35 @@ export default {
|
|
|
return {
|
|
|
labelPosition: 'right',
|
|
|
sizeForm: {
|
|
|
- nickname: '',
|
|
|
- uscc: '',
|
|
|
- photoFront: '',
|
|
|
- businessLicense: '',
|
|
|
- photoBackside: '',
|
|
|
- name: '',
|
|
|
- establishedAt: '',
|
|
|
+ realName: '',
|
|
|
+ orgLicenseExpire: '',
|
|
|
+ idFront: '',
|
|
|
+ orgLicense: '',
|
|
|
+ idBack: '',
|
|
|
+ orgName: '',
|
|
|
+ orgNo: '',
|
|
|
// phone: '',
|
|
|
- IDs: ''
|
|
|
+ idNo: '',
|
|
|
+ radio: '1'
|
|
|
},
|
|
|
typeFl: {},
|
|
|
registerRule: {
|
|
|
- uscc: { required: true, min: 18, max: 18, message: '请输入18位统一社会信用代码', trigger: 'blur' },
|
|
|
- IDs: { required: true, min: 18, max: 18, message: '请输入18位身份证号', trigger: 'blur' },
|
|
|
- nickname: { required: true, message: '请输入您的真实姓名', trigger: 'blur' },
|
|
|
- establishedAt: { required: true, message: '请选择', trigger: 'blur' },
|
|
|
- name: { required: true, message: '请输入企业名称', trigger: 'blur' },
|
|
|
+ orgNo: {
|
|
|
+ required: true,
|
|
|
+ min: 18,
|
|
|
+ max: 18,
|
|
|
+ message: '请输入18位统一社会信用代码',
|
|
|
+ trigger: 'blur'
|
|
|
+ },
|
|
|
+ idNo: { required: true, min: 18, max: 18, message: '请输入18位身份证号', trigger: 'blur' },
|
|
|
+ realName: { required: true, message: '请输入', trigger: 'blur' },
|
|
|
+ orgLicenseExpire: { required: true, message: '请选择', trigger: 'blur' },
|
|
|
+ // orgNo: { required: true, message: '请选择', trigger: 'blur' },
|
|
|
+ orgName: { required: true, message: '请输入企业名称', trigger: 'blur' },
|
|
|
// phone: { required: true, message: '请输入您的联系方式', trigger: 'blur' },
|
|
|
- email: { type: 'email', required: true, message: '请输入您的邮箱', trigger: 'blur' },
|
|
|
- photoFront: { required: true, message: '请添加您的法人身份证(正面)', trigger: 'blur' },
|
|
|
- photoBackside: { required: true, message: '请添加您的法人身份证(反面)', trigger: 'blur' },
|
|
|
- businessLicense: { required: true, message: '请添加营业执照', trigger: 'blur' }
|
|
|
+ idFront: { required: true, message: '请添加您的法人身份证(正面)', trigger: 'blur' },
|
|
|
+ idBack: { required: true, message: '请添加您的法人身份证(反面)', trigger: 'blur' },
|
|
|
+ orgLicense: { required: true, message: '请添加营业执照', trigger: 'blur' }
|
|
|
}
|
|
|
};
|
|
|
},
|
|
|
@@ -123,7 +153,7 @@ export default {
|
|
|
// .then(res => {
|
|
|
// this.sizeForm = {
|
|
|
// ...res,
|
|
|
- // nickname: this.userInfo.nickname,
|
|
|
+ // realName: this.userInfo.realName,
|
|
|
// phone: this.userInfo.phone,
|
|
|
// avatar: this.userInfo.avatar,
|
|
|
// email: this.userInfo.email
|
|
|
@@ -137,6 +167,13 @@ export default {
|
|
|
Jump() {
|
|
|
this.$router.go(-1);
|
|
|
},
|
|
|
+ Jump2() {
|
|
|
+ let status = 'NOT_AUTH';
|
|
|
+ this.updateUser({ authStatus: status }).then(res => {
|
|
|
+ // console.log(res);
|
|
|
+ this.$router.push('/accountdata');
|
|
|
+ });
|
|
|
+ },
|
|
|
onSubmit() {
|
|
|
this.$refs.form.validate(valid => {
|
|
|
if (valid) {
|
|
|
@@ -147,44 +184,21 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
preservation() {
|
|
|
- let data = { ...this.sizeForm };
|
|
|
- delete data.nickname;
|
|
|
- delete data.phone;
|
|
|
- delete data.email;
|
|
|
- data.userId = this.userInfo.id;
|
|
|
- this.saving = true;
|
|
|
- let userInfo = {
|
|
|
- ...this.userInfo,
|
|
|
- nickname: this.sizeForm.nickname,
|
|
|
- phone: this.sizeForm.phone,
|
|
|
- avatar: this.userInfo.avatar,
|
|
|
- email: this.sizeForm.email
|
|
|
- };
|
|
|
- userInfo.authorities = [
|
|
|
- ...userInfo.authorities,
|
|
|
- {
|
|
|
- name: 'ROLE_INSTITUTION'
|
|
|
- }
|
|
|
- ];
|
|
|
- console.log(userInfo);
|
|
|
- // this.$http
|
|
|
- // .post('user/save', userInfo, {
|
|
|
- // body: 'json'
|
|
|
- // })
|
|
|
- // .then(res => {
|
|
|
- // this.sizeForm.avatar = res.avatar;
|
|
|
- // this.$store.dispatch('getUserInfo');
|
|
|
- // return this.$http.post('/institution/save', data, { body: 'json' }).then(res => {
|
|
|
- // this.sizeForm = res;
|
|
|
- // this.saving = false;
|
|
|
- // this.$store.dispatch('getUserInfo');
|
|
|
- // });
|
|
|
- // })
|
|
|
- // .catch(e => {
|
|
|
- // console.log(e);
|
|
|
- // this.saving = false;
|
|
|
- // this.$message.error(e.error);
|
|
|
- // });
|
|
|
+ let form = { ...this.sizeForm };
|
|
|
+ form.userId = this.userInfo.id;
|
|
|
+ form.status = 'PENDING';
|
|
|
+ form.org = true;
|
|
|
+ console.log(form);
|
|
|
+ // let org = false;
|
|
|
+ // this.updateUser({ org: org }).then(res => {
|
|
|
+ this.$http
|
|
|
+ .post('/identityAuth/apply', {
|
|
|
+ ...form
|
|
|
+ })
|
|
|
+ .then(res => {
|
|
|
+ this.$store.dispatch('getUserInfo', res);
|
|
|
+ });
|
|
|
+ // });
|
|
|
}
|
|
|
}
|
|
|
};
|
|
|
@@ -206,7 +220,13 @@ export default {
|
|
|
color: #ffffff;
|
|
|
}
|
|
|
/deep/ .el-form-item__error {
|
|
|
- margin-left: 294px;
|
|
|
+ // margin-left: 194px;
|
|
|
+ }
|
|
|
+ /deep/ .el-form-item__content {
|
|
|
+ display: flex;
|
|
|
+ }
|
|
|
+ /deep/ .el-radio {
|
|
|
+ margin-top: 14px;
|
|
|
}
|
|
|
/deep/ .el-button {
|
|
|
width: 130px;
|
|
|
@@ -234,6 +254,11 @@ export default {
|
|
|
margin-left: 20px;
|
|
|
}
|
|
|
}
|
|
|
+ .content {
|
|
|
+ display: flex;
|
|
|
+ width: 670px;
|
|
|
+ justify-content: space-between;
|
|
|
+ }
|
|
|
.title {
|
|
|
height: 42px;
|
|
|
font-size: 32px;
|