Commit 22285a92 authored by dragondean@qq.com's avatar dragondean@qq.com

修复订单线路未回显

parent d50d6e07
......@@ -893,26 +893,26 @@ export default {
console.log('departureId', departureId)
this.getOpenedRouterList()
// 修改始发地后需要重新选择路线
if(oldDepartureId && oldDepartureId != departureId && !this.initing){
/* if(oldDepartureId && oldDepartureId != departureId && !this.initing){
console.log('修改始发地,重置lineId', oldDepartureId, departureId)
this.$set(this.form, 'lineId', null)
}
} */
},
// 目的地
async 'form.objectiveId'(objectiveId, oldObjectiveId){
// 重新获取路线
await this.getOpenedRouterList()
// 如果已选择的路线不在可用路线里则重置
if(this.form.lineId && !this.routerList.find(item => item.id == this.form.lineId)){
/* if(this.form.lineId && !this.routerList.find(item => item.id == this.form.lineId)){
this.$set(this.form, 'lineId', null)
}
} */
// 重新获取渠道
await this.getChannelList()
// 如果已选择的渠道不在可用渠道里则重置
if(this.form.channelId && !this.channelList.find(item => item.channelId == this.form.channelId)){
/* if(this.form.channelId && !this.channelList.find(item => item.channelId == this.form.channelId)){
this.$set(this.form, 'channelId', null)
}
} */
},
'form.transportId'(transportId, oldTransportId){
// 空运
......@@ -928,10 +928,10 @@ export default {
})
}
// 更换运输方式之后,之前选择的路线会失效,需要重新选择
if(oldTransportId && oldTransportId != transportId && transportId != this.selectedRouter?.transportType && !this.initing){
/* if(oldTransportId && oldTransportId != transportId && transportId != this.selectedRouter?.transportType && !this.initing){
console.log('重置路线',oldTransportId, transportId, this.selectedRouter?.transportType)
this.$set(this.form, 'lineId', undefined)
}
} */
// 选择海运拼柜和海运整柜清空渠道值
if(transportId == 1 || transportId == 2){
......@@ -960,10 +960,10 @@ export default {
}
// 更新线路备选
await this.getOpenedRouterList()
// 如果已选择路线且切换后原路线不可用则重置
/* // 如果已选择路线且切换后原路线不可用则重置
if(this.form.lineId && !this.routerList.find(item => item.id == this.form.lineId)){
this.$set(this.form, 'lineId', null)
}
} */
})
},
'form.consigneeCountryCode'(){
......@@ -979,6 +979,7 @@ export default {
if(this.form.lineId) this.getOfferData()
},
async 'form.lineId'(lineId){
console.log("路线修改", lineId)
let router = this.routerList.find(item => item.id == lineId)
if(!router){
return
......@@ -1250,6 +1251,7 @@ export default {
}
this.$nextTick(() => {
this.initing = false
console.log("initing", this.initing)
})
}, 100)
......
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