CRM_26-04-22#story#8495,潜在供应商H5页面提交信息,信息审核,提交补充信息与退回理由的优化与修复(停启用修改)

This commit is contained in:
2026-06-09 11:06:48 +08:00
parent e4757849dd
commit 57f839166e
6 changed files with 28 additions and 6 deletions

View File

@@ -222,6 +222,12 @@ export default {
this.identityCardFront = this.$route.params?.identityCardFront;
this.driverInfo.lssueDate = this.$route.params?.lssueDate;
this.drivingLicenceName = this.$route.params?.drivingLicenceName;
// 获取 fromSupplierAdd 标识
const fromSupplierAdd = this.$route.params?.fromSupplierAdd;
// 如果从 supplierAdd 进入且不是修改模式,默认设置为停用状态
if(!this.id && fromSupplierAdd === 'true') {
this.states = 0;
}
if( this.identityCardFront ) {
this.identityCardFrontList = [{ url : this.identityCardFront }];
}

View File

@@ -137,6 +137,7 @@ export default {
supplierId: '',
routeId: '',
initialized: false,
fromSupplierAdd: '', // 是否从 supplierAdd 进入
supplierType:'',
count: 0,
isLoading: false,
@@ -186,6 +187,8 @@ export default {
this.supplierId = rawId ? Number(rawId) : '';
const potentialId = this.$route.query.potentialId || urlParams.get('potentialId');
this.routeId = potentialId;
// 获取 fromSupplierAdd 标识
this.fromSupplierAdd = this.$route.query.fromSupplierAdd || urlParams.get('fromSupplierAdd') || '';
if(!rawId) {
this.getPermissions();
}
@@ -255,7 +258,7 @@ export default {
}else{
this.$router.push({
name: 'driverAdd',
params: this.supplierId ? { supplierId: this.supplierId } : {}
params: this.supplierId ? { supplierId: this.supplierId, fromSupplierAdd: this.fromSupplierAdd } : {}
})
}
},

View File

@@ -323,6 +323,10 @@
});
this.wechatId = res?.data?.wechatId
},
isFromSupplierAdd() {
// 判断是否从 supplierAdd 进入
return this.$route.name === 'supplierAdd' || this.$route.query.fromSupplierAdd === 'true';
},
async saveHandler() {
if( this.clickFlag ) {
try {

View File

@@ -166,8 +166,8 @@
methods: {
goAddVehicle() {
const supplierId = this.id
localStorage.setItem('lastRoute', JSON.stringify({ name: 'vehicleManage', query: { id: supplierId } }));
this.goPage('vehicleManage', { id: supplierId });
localStorage.setItem('lastRoute', JSON.stringify({ name: 'vehicleManage', query: { id: supplierId, fromSupplierAdd: 'true' } }));
this.goPage('vehicleManage', { id: supplierId, fromSupplierAdd: 'true' });
},
goModifyPage() {
this.goPage('supplierAdd', { id : this.id })

View File

@@ -689,6 +689,8 @@ export default {
const urlParams = new URLSearchParams(window.location.search);
const rawId = this.$route.query.supplierId || urlParams.get('supplierId');
this.supplierId = rawId ? Number(rawId) : '';
// 获取 fromSupplierAdd 标识
const fromSupplierAdd = this.$route.query.fromSupplierAdd || urlParams.get('fromSupplierAdd');
await this.getSupplierServiceTree();
await this.getTypeList();
if( this.id){
@@ -705,6 +707,10 @@ export default {
liabilityInsuranceEndTime:'',
insurancePicturePhoto:''
}
// 如果从 supplierAdd 进入,默认设置为停用状态
if(fromSupplierAdd === 'true') {
this.vehicleStatus = 2;
}
}
},
methods:{

View File

@@ -11,7 +11,7 @@
@click-left="goBack"
>
<template slot="right" v-if="permissonList.includes('vehicleAddBtn') || supplierId">
<div class="rightWrap" @click="goPage('vehicleAdd', supplierId ? { supplierId } : {})">
<div class="rightWrap" @click="goPage('vehicleAdd', supplierId ? { supplierId, fromSupplierAdd } : {})">
<img src="@/assets/addImg.png" />
<span class="addTxt">添加</span>
</div>
@@ -149,6 +149,7 @@ export default {
searchVal: '',
authStates: [],
liabilityInsuranceAuditList: [],
fromSupplierAdd: '', // 是否从 supplierAdd 进入
inputStatusListOptions: [{
name: '行驶证未录入',
value: 0
@@ -205,6 +206,8 @@ export default {
} else {
this.initialized = true;
}
// 获取 fromSupplierAdd 标识
this.fromSupplierAdd = this.$route.query.fromSupplierAdd || urlParams.get('fromSupplierAdd') || '';
let _token = localStorage.getItem('token')
if( _token ) {
this.getPermissions();
@@ -212,8 +215,8 @@ export default {
},
methods:{
nextToDriver() {
localStorage.setItem('lastRoute', JSON.stringify({ name: 'driverManage', query: { id: this.supplierId, potentialId: this.routeId } }));
this.goPage('driverManage', { id: this.supplierId, potentialId: this.routeId });
localStorage.setItem('lastRoute', JSON.stringify({ name: 'driverManage', query: { id: this.supplierId, potentialId: this.routeId, fromSupplierAdd: this.fromSupplierAdd } }));
this.goPage('driverManage', { id: this.supplierId, potentialId: this.routeId, fromSupplierAdd: this.fromSupplierAdd });
},
async getSupplierById(id) {
let res = await supplierSelectById({ id });