Merge remote-tracking branch 'origin/dev' into dev

This commit is contained in:
2022-11-24 18:04:55 +08:00

View File

@@ -110,7 +110,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="form-item form-item__textarea"> <!-- <div class="form-item form-item__textarea">
<div class="form-item__wrapper"> <div class="form-item__wrapper">
<div class="form-item__title"> <div class="form-item__title">
<i style="margin-right:8px;"></i> <i style="margin-right:8px;"></i>
@@ -121,7 +121,7 @@
placeholder-style="font-size: 16px"></textarea> placeholder-style="font-size: 16px"></textarea>
</div> </div>
</div> </div>
</div> </div> -->
<!-- <div class="form-item form-item__imgs"> <!-- <div class="form-item form-item__imgs">
<div class="form-item__wrapper"> <div class="form-item__wrapper">
<div class="form-item__title"> <div class="form-item__title">
@@ -274,7 +274,7 @@
</div> --> </div> -->
<!-- 同行情况 --> <!-- 同行情况 -->
<!-- <div class="title">同行情况</div> <div class="title">同行情况</div>
<div class="form-item__group"> <div class="form-item__group">
<div class="form-item"> <div class="form-item">
<div class="form-item__wrapper"> <div class="form-item__wrapper">
@@ -294,7 +294,7 @@
:phone.sync="item.phone" :index="index" @delCountHandle="delCountHandle"/> :phone.sync="item.phone" :index="index" @delCountHandle="delCountHandle"/>
</div> </div>
<div class="addCount" @click="addCountHandle" v-if="form.companionCount > 0">添加同行人</div> <div class="addCount" @click="addCountHandle" v-if="form.companionCount > 0">添加同行人</div>
</div> --> </div>
<u-picker mode="time" :params="params" v-model="isShowStartTime" @confirm="onStartChange"></u-picker> <u-picker mode="time" :params="params" v-model="isShowStartTime" @confirm="onStartChange"></u-picker>
<u-picker mode="time" :params="params" v-model="isShowEndTime" @confirm="onEndChange"></u-picker> <u-picker mode="time" :params="params" v-model="isShowEndTime" @confirm="onEndChange"></u-picker>
@@ -449,9 +449,9 @@ export default {
this.people.splice(index, 1); this.people.splice(index, 1);
}, },
onStartChange(e) { // onStartChange(e) {
this.form.startTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}` // this.form.startTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}`
}, // },
onEndChange(e) { onEndChange(e) {
this.form.arriveTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}` this.form.arriveTime = `${e.year}-${e.month}-${e.day} ${e.hour}:${e.minute}`
@@ -472,7 +472,7 @@ export default {
this.form = res.data this.form = res.data
this.people = res.data.companionList this.people = res.data.companionList
this.travelType = res.data.travelType?.split(',') this.travelType = res.data.travelType?.split(',')
this.form.startTime = res.data.startTime.substr(0, res.data.startTime.length - 3) // this.form.startTime = res.data.startTime.substr(0, res.data.startTime.length - 3)
this.form.arriveTime = res.data.arriveTime.substr(0, res.data.arriveTime.length - 3) this.form.arriveTime = res.data.arriveTime.substr(0, res.data.arriveTime.length - 3)
this.startAreaId = res.data.startAreaId this.startAreaId = res.data.startAreaId
this.startAreaName = res.data.startAreaName this.startAreaName = res.data.startAreaName
@@ -526,7 +526,7 @@ export default {
this.startAreaName = res.data.startAreaName this.startAreaName = res.data.startAreaName
this.form.arriveAreaId = res.data.arriveAreaId this.form.arriveAreaId = res.data.arriveAreaId
this.form.arriveAreaName = res.data.arriveAreaName this.form.arriveAreaName = res.data.arriveAreaName
this.form.startAddress = res.data.startAddress || '' // this.form.startAddress = res.data.startAddress || ''
this.form.arriveAddress = res.data.arriveAddress || '' this.form.arriveAddress = res.data.arriveAddress || ''
} }
}) })
@@ -571,7 +571,7 @@ export default {
// } // }
if (!this.startAreaId) { if (!this.startAreaId) {
return this.$toast('请选择出发地') return this.$toast('请选择从哪来')
} }
if (this.startAreaId.substr(4,this.startAreaId.length - 4) === '00000000') { if (this.startAreaId.substr(4,this.startAreaId.length - 4) === '00000000') {
@@ -590,12 +590,12 @@ export default {
return this.$toast('请选择抵平时间') return this.$toast('请选择抵平时间')
} }
if (new Date(this.form.startTime.replace(/-/g, '/')).getTime() >= new Date(this.form.arriveTime.replace(/-/g, '/')).getTime()) { // if (new Date(this.form.startTime.replace(/-/g, '/')).getTime() >= new Date(this.form.arriveTime.replace(/-/g, '/')).getTime()) {
return this.$toast('到达时间不得早于出发时间') // return this.$toast('到达时间不得早于出发时间')
} // }
if (!this.form.arriveAreaName) { if (!this.form.arriveAreaName) {
return this.$toast('请选择目的地') return this.$toast('请选择到哪去')
} }
if (this.form.arriveAreaId.substr(this.form.arriveAreaId.length - 3, 3) === '000') { if (this.form.arriveAreaId.substr(this.form.arriveAreaId.length - 3, 3) === '000') {
@@ -630,25 +630,25 @@ export default {
// } // }
// } // }
// if (!this.form.companionCount || this.form.companionCount == 0) { if (!this.form.companionCount || this.form.companionCount == 0) {
// this.form.companionCount = 0 this.form.companionCount = 0
// this.form.companionList = [] this.form.companionList = []
// } else { } else {
// if(this.form.companionCount > 100) { if(this.form.companionCount > 100) {
// return this.$u.toast('同行人数最多可填写100人。') return this.$u.toast('同行人数最多可填写100人。')
// } }
// if(this.people.length != this.form.companionCount) { if(this.people.length != this.form.companionCount) {
// return this.$u.toast('请输入正确的同行人信息') return this.$u.toast('请输入正确的同行人信息')
// } else { } else {
// if(this.people.some(val=> (val.name=='') || (val.phone=='')) ) { if(this.people.some(val=> (val.name=='') || (val.phone=='')) ) {
// return this.$u.toast('请输入完整的同行人信息') return this.$u.toast('请输入完整的同行人信息')
// } else { } else {
// this.form.companionList = this.people this.form.companionList = this.people
// } }
// } }
// } }
if (this.flag) return if (this.flag) return
this.flag = true this.flag = true
@@ -659,7 +659,7 @@ export default {
startAreaId: this.startAreaId, startAreaId: this.startAreaId,
startAreaName: this.startAreaName, startAreaName: this.startAreaName,
travelType: this.travelType.toString(), travelType: this.travelType.toString(),
startTime: this.form.startTime + ':00', // startTime: this.form.startTime + ':00',
arriveTime: this.form.arriveTime + ':00', arriveTime: this.form.arriveTime + ':00',
}).then(res => { }).then(res => {
this.$hideLoading() this.$hideLoading()