Commit a53b03dc authored by 18224442217's avatar 18224442217

no message

parent b337277c
......@@ -407,18 +407,25 @@
x.time = ''
x.week = ''
x.duration = ''
x.frequency = 0
x.show = true
});
}
arr(res.data.FlightList)
this.DetailsList = res.data.FlightList
this.DetailsList = res.data.FlightList
let FlightListZ =this.DetailsList.filter(z=>{
return z.FlightSubType!=3
})
let FlightListZ2 = this.DetailsList.filter(z=>{
return z.FlightSubType==3
})
this.DetailsList.forEach(y=>{
let date = y.FlightDate.split('-')
y.time = `${date[1]}-${date[2]}`
y.week = getDateWeek(y.FlightDate)
y.duration = `${y.DepartureTime.Days>0?y.DepartureTime.Days+'d ':''}${y.DepartureTime.Hours>0?y.DepartureTime.Hours+'h ':''}${y.DepartureTime.Minutes>0?y.DepartureTime.Minutes+'m ':''}`
y.frequency = this.DetailsList.length-2>1?this.DetailsList.length-2:0
})
let FlightList = []
let NewFlightList = []
......@@ -447,6 +454,7 @@
let obj = {
FlightList: FlightList,
NewFlightList: NewFlightList,
frequency: FlightListZ.length-1,
...this.DetailsList[0]
}
this.NewDetailsList.push(obj)
......@@ -456,6 +464,7 @@
let obj = {
FlightList: FlightList2,
NewFlightList: NewFlightList2,
frequency: FlightListZ2.length-1,
...this.DetailsList[this.DetailsList.length-1]
}
this.NewDetailsList.push(obj)
......
......@@ -110,7 +110,6 @@
x.week = ''
x.duration = ''
x.frequency = 0
x.frequencyA = 0
x.different = 0 //是否异地
x.NewFlightList = []
x.loading = false
......@@ -121,7 +120,6 @@
arr(x.flightList)
})
res.data.pageData.forEach(x=>{
if(x.flightList.length>2){
x.different = 1
}
......@@ -132,26 +130,18 @@
let FlightList2 = x.flightList.filter(z=>{
return z.flightSubType==3
})
x.frequency = FlightList.length-1
x.frequencyA = FlightList2.length-1
x.flightList.forEach((y,index)=>{
if(y.flightSubType!=3&&x.flightList.length>2){
x.frequency+=1
}
if(y.flightSubType==3){
x.frequencyA+=1
}
x.flightList.forEach((y,index)=>{
let date = y.flightDate.split('-')
y.time = `${date[1]}-${date[2]}`
y.week = getDateWeek(y.flightDate)
if(index==0){
y.frequency = x.frequency
y.frequency = FlightList.length-1
y.duration = `${x.departureTime.days>0?x.departureTime.days+'d ':''}${x.departureTime.hours>0?x.departureTime.hours+'h ':''}${x.departureTime.minutes>0?x.departureTime.minutes+'m ':''}`
x.NewFlightList.push(y)
}
if(x.flightList.length-1==index){
y.frequency = x.frequencyA
y.frequency = FlightList2.length-1
y.duration = `${x.arrivalTime.days>0?x.arrivalTime.days+'d ':''}${x.arrivalTime.hours>0?x.arrivalTime.hours+'h ':''}${x.arrivalTime.minutes>0?x.arrivalTime.minutes+'m ':''}`
x.NewFlightList.push(y)
}
......@@ -164,6 +154,7 @@
this.dataList = this.dataList.concat(res.data.pageData);
}
this.pageCount = res.data.pageCount;
if(this.pageCount==1) this.status = "nomore";
}
uni.hideLoading()
}
......
......@@ -25,7 +25,7 @@
<text>已选:
<!-- {{orderMsg.GuestNum}} <text class="fz22"></text> -->
</text>
<text class="ML30" v-if="orderMsg.ManNum>0">{{orderMsg.ManNum}} <text class="fz22">成人</text></text>
<text v-if="orderMsg.ManNum>0">{{orderMsg.ManNum}} <text class="fz22">成人</text></text>
<text class="ML30" v-if="orderMsg.BabyNum>0">{{orderMsg.BabyNum}} <text class="fz22">婴儿</text></text>
<text class="ML30" v-if="orderMsg.ChirdNum>0">{{orderMsg.ChirdNum}} <text class="fz22">儿童</text></text>
</view>
......@@ -455,16 +455,29 @@
}
arr(res.data.FlightList)
this.DetailsList = res.data.FlightList
let FlightListZ =this.DetailsList.filter(z=>{
return z.FlightSubType!=3
})
let FlightListZ2 = this.DetailsList.filter(z=>{
return z.FlightSubType==3
})
this.DetailsList.forEach((y,index)=>{
let date = y.FlightDate.split('-')
y.time = `${date[1]}-${date[2]}`
y.week = getDateWeek(y.FlightDate)
if(index){
y.frequency = FlightListZ2.length-1
y.duration = `${y.ArrivalTime.Days>0?y.ArrivalTime.Days+'d ':''}${y.ArrivalTime.Hours>0?y.ArrivalTime.Hours+'h ':''}${y.ArrivalTime.Minutes>0?y.ArrivalTime.Minutes+'m ':''}`
}else{
y.frequency = FlightListZ.length-1
y.duration = `${y.DepartureTime.Days>0?y.DepartureTime.Days+'d ':''}${y.DepartureTime.Hours>0?y.DepartureTime.Hours+'h ':''}${y.DepartureTime.Minutes>0?y.DepartureTime.Minutes+'m ':''}`
}
})
let FlightList = []
let NewFlightList = []
let FlightList2 = []
......
......@@ -344,18 +344,16 @@
Days2 = new Set(NewFlightDates2)
}
y.frequency = FlightList.length-1
y.frequencyA = FlightList2.length-1
let obj = {
duration:`${y.DepartureTime.Days>0?y.DepartureTime.Days+'d ':''}${y.DepartureTime.Hours>0?y.DepartureTime.Hours+'h ':''}${y.DepartureTime.Minutes>0?y.DepartureTime.Minutes+'m ':''}`,
frequency: y.frequency,
frequency: FlightList.length-1,
Days: Array.from(Days).length>1?Array.from(Days).length:1,
...y.FlightList[0]
}
let obj2 = {
duration:`${y.ArrivalTime.Days>0?y.ArrivalTime.Days+'d ':''}${y.ArrivalTime.Hours>0?y.ArrivalTime.Hours+'h ':''}${y.ArrivalTime.Minutes>0?y.ArrivalTime.Minutes+'m ':''}`,
Days: Array.from(Days2).length>1?Array.from(Days2).length:1,
frequency: y.frequencyA,
frequency: FlightList2.length-1,
...y.FlightList[y.FlightList.length-1]
}
y.NewFlightList.push(obj)
......
......@@ -52,9 +52,9 @@
</view>
</view>
<view class="flexG relative">
<view v-if="index!=0" class="airTicketDetailsCard-ZhuanNum bgE1C278 fz18 colorFFF absolute">
<view v-if="items.frequency&&index!=0" class="airTicketDetailsCard-ZhuanNum bgE1C278 fz18 colorFFF absolute">
<template v-if="items.FlightList.length-1>1">+{{items.FlightList.length-1}}</template>
<template v-if="items.frequency>1">+{{items.frequency}}</template>
</view>
<view class="airTicketDetailsCard-title row-aic-n absolute" v-if="index==0">
<img class="inlineblock flexS" mode="widthFix" style="width: 20rpx;height: 17rpx;"
......
......@@ -50,9 +50,9 @@
</view>
</view>
<view class="column flexG relative">
<view v-if="index!=0" class="airTicketDetailsCard-ZhuanNum bgE1C278 fz18 colorFFF absolute">
<view v-if="items.frequency&&index!=0" class="airTicketDetailsCard-ZhuanNum bgE1C278 fz18 colorFFF absolute">
<template v-if="items.FlightList.length-1>1">+{{items.FlightList.length-1}}</template>
<template v-if="items.frequency>1">+{{items.frequency}}</template>
</view>
<view class="airTicketDetailsCard-title row-aic-n absolute" v-if="index==0">
<img class="inlineblock flexS" mode="widthFix" style="width: 20rpx;height: 17rpx;"
......
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