|
|
|
@ -642,6 +642,12 @@
|
|
|
|
this.getLabel()
|
|
|
|
this.getLabel()
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
|
|
|
|
syncCarsToForm() {
|
|
|
|
|
|
|
|
// 让表单校验字段与表格编辑值实时同步,避免“已填车牌但校验仍失败”
|
|
|
|
|
|
|
|
this.form.cars = (this.carsList || [])
|
|
|
|
|
|
|
|
.map(item => (item && item.car ? String(item.car).trim() : ""))
|
|
|
|
|
|
|
|
.filter(Boolean)
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
async getDetail() {
|
|
|
|
async getDetail() {
|
|
|
|
const res = await show({
|
|
|
|
const res = await show({
|
|
|
|
@ -818,6 +824,7 @@
|
|
|
|
},
|
|
|
|
},
|
|
|
|
submit() {
|
|
|
|
submit() {
|
|
|
|
let that = this
|
|
|
|
let that = this
|
|
|
|
|
|
|
|
this.syncCarsToForm()
|
|
|
|
if(that.form.credent==1){
|
|
|
|
if(that.form.credent==1){
|
|
|
|
const regtest = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/
|
|
|
|
const regtest = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/
|
|
|
|
if(!regtest.test(that.form.idcard)){
|
|
|
|
if(!regtest.test(that.form.idcard)){
|
|
|
|
@ -833,11 +840,7 @@
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
that.form.follw_people = that.followList
|
|
|
|
that.form.follw_people = that.followList
|
|
|
|
let _car = []
|
|
|
|
this.syncCarsToForm()
|
|
|
|
for(var k of that.carsList){
|
|
|
|
|
|
|
|
_car.push(k.car)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
this.form.cars = _car
|
|
|
|
|
|
|
|
console.log("this.form.cars",this.form.cars)
|
|
|
|
console.log("this.form.cars",this.form.cars)
|
|
|
|
// return
|
|
|
|
// return
|
|
|
|
if(this.visitType==3){
|
|
|
|
if(this.visitType==3){
|
|
|
|
@ -859,6 +862,12 @@
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
watch: {
|
|
|
|
watch: {
|
|
|
|
|
|
|
|
carsList: {
|
|
|
|
|
|
|
|
deep: true,
|
|
|
|
|
|
|
|
handler() {
|
|
|
|
|
|
|
|
this.syncCarsToForm()
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
isShow(newVal) {
|
|
|
|
isShow(newVal) {
|
|
|
|
if (newVal) {
|
|
|
|
if (newVal) {
|
|
|
|
console.log("this.visitType",this.visitType)
|
|
|
|
console.log("this.visitType",this.visitType)
|
|
|
|
|