Commit caa9dd62 authored by dcy's avatar dcy

会员认证修改

parent 0e82810f
......@@ -244,7 +244,7 @@ import FileUpload from "@/components/FileUpload"
import ImageUpload from "@/components/ImageUpload";
import uploadImage from "@/components/UploadImage";
import {CommonStatusEnum} from "@/utils/constants";
import {changeUserStatus} from "@/api/system/user";
import {changeUserStatus, listServiceUser, listSimpleUsers} from "@/api/system/user";
let stateId = {
0:'审核中',
......@@ -492,11 +492,12 @@ export default {
userCardAuthId:this.IdDetails.id,
auditRemark:this.IdDetails.auditRemark
}
if(val === 3){
if(val === 2){
p.auditRemark = undefined
}
memberUserAuditIdCard(p).then(r => {
if(r.code === 0){
this.$message.success('修改成功');
this.getList()
this.getIdentityDetails()
}
......@@ -509,7 +510,7 @@ export default {
userCardAuthId:this.enterpriseFrom.id,
auditRemark:this.enterpriseFrom.auditRemark
}
if(val === 3){
if(val === 2){
p.auditRemark = undefined
}
memberUserAuditEnterprise(p).then(r => {
......@@ -520,67 +521,77 @@ export default {
})
},
setMemberUserUpdateIdCard(){
this.$refs.formId.validate(valid =>{
if(valid){
let p ={
cardNumber:this.IdDetails.cardNumber,
cardType:this.IdDetails.cardType,
img1:this.IdDetails.img1,
img2:this.IdDetails.img2,
name:this.IdDetails.name,
userCardAuthId:this.IdDetails.id,
auditPass:this.IdDetails.status === 3 ? true : false,
} ;
memberUserUpdateIdCard(p).then(r => {
if(r.code === 0){
if(this.IdDetails.status === 3){
this.$confirm('是否要将当前状态修改为审核成功?', '状态修改', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.idCardAuditFn(2);
}).catch(() => {
this.getIdentityDetails()
});
}
this.getList()
this.$message.success('修改成功');
}
})
this.$refs.formId.validate(async valid =>{
let p ={
cardNumber:this.IdDetails.cardNumber,
cardType:this.IdDetails.cardType,
img1:this.IdDetails.img1,
img2:this.IdDetails.img2,
name:this.IdDetails.name,
userCardAuthId:this.IdDetails.id,
};
if(valid && this.IdDetails.status === 3){
let res = await new Promise((resolve)=>{
this.$confirm('是否要将当前状态修改为审核成功?', '状态修改', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(r =>{
resolve(r)
}).catch((r)=>{
resolve(r)
})
})
p.auditPass = res === 'confirm' ? true : false;
} else if(valid) {
p.auditPass = false;
} else {
return
}
memberUserUpdateIdCard(p).then(r => {
if(r.code === 0){
this.$message.success('修改成功')
if(p.auditPass === true ){
this.getIdentityDetails()
}
this.getList()
}
})
})
},
setMemberUserUpdateEnterprise(){
this.$refs.formEnter.validate(valid =>{
if(valid){
let p = {
cardNumber:this.enterpriseFrom.cardNumber,
img1:this.enterpriseFrom.img1,
img2:this.enterpriseFrom.img2,
legalName:this.enterpriseFrom.legalName,
name:this.enterpriseFrom.name,
userEnterpriseAuthId:this.enterpriseFrom.id,
auditPass:this.enterpriseFrom.status === 3 ? true : false,
}
memberUserUpdateEnterprise(p).then(r =>{
if(r.code === 0){
if(this.enterpriseFrom.status === 3){
this.$confirm('是否要将当前状态修改为审核成功?', '状态修改', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
this.certificateVerificationFn(2);
}).catch(() => {
this.getEnterpriseFn();
});
}
this.getList()
this.$message.success('修改成功');
}
this.$refs.formEnter.validate(async valid =>{
let p = {
cardNumber:this.enterpriseFrom.cardNumber,
img1:this.enterpriseFrom.img1,
img2:this.enterpriseFrom.img2,
legalName:this.enterpriseFrom.legalName,
name:this.enterpriseFrom.name,
userEnterpriseAuthId:this.enterpriseFrom.id,
}
if(valid && this.enterpriseFrom.status === 3){
let res = await new Promise((resolve)=>{
this.$confirm('是否要将当前状态修改为审核成功?', '状态修改', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(r =>resolve(r)).catch(r => resolve(r))
})
p.auditPass = res === 'confirm' ? true : false;
}else if(valid){
p.auditPass = false;
}else {
return
}
memberUserUpdateEnterprise(p).then(r =>{
if(r.code === 0){
if(p.auditPass === 3){
this.getEnterpriseFn();
}
this.getList()
this.$message.success('修改成功');
}
})
})
},
authentication(row){
......@@ -608,10 +619,9 @@ export default {
console.log(r);
if(r.code === 0){
this.$message.success('添加成功!');
this.enterpriseFrom.status = 3
this.enterpriseFrom.status = 2
this.enterpriseFrom.auditTime = new Date().getTime()
this.getEnterpriseFn();
}
})
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment