Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
J
jz_Travel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhengke
jz_Travel
Commits
493f8d57
Commit
493f8d57
authored
Oct 23, 2023
by
18224442217
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
679b0bbb
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
64 additions
and
27 deletions
+64
-27
TicketOrderDetails.vue
pages/airTicket/TicketOrderDetails.vue
+13
-6
TicketOrderList.vue
pages/airTicket/TicketOrderList.vue
+14
-1
airTicketDetails.vue
pages/airTicket/airTicketDetails.vue
+9
-9
airTicketList.vue
pages/airTicket/airTicketList.vue
+19
-4
TicketOrderDetails.vue
pages/airTicket/components/TicketOrderDetails.vue
+1
-1
TicketOrderList.vue
pages/airTicket/components/TicketOrderList.vue
+1
-1
airTicketList.vue
pages/airTicket/components/airTicketList.vue
+7
-5
No files found.
pages/airTicket/TicketOrderDetails.vue
View file @
493f8d57
...
...
@@ -426,17 +426,24 @@
let
NewFlightList2
=
[]
for
(
let
i
=
0
;
i
<
this
.
DetailsList
.
length
;
i
++
){
if
(
this
.
DetailsList
.
length
-
1
!=
i
){
if
(
this
.
DetailsList
.
length
-
1
!=
i
&&
this
.
DetailsList
[
i
].
FlightSubType
!=
3
){
FlightList
.
push
(
this
.
DetailsList
[
i
])
if
(
this
.
DetailsList
.
length
-
2
==
i
||
i
==
0
){
NewFlightList
.
push
(
this
.
DetailsList
[
i
])
}
}
else
{
FlightList2
.
push
(
this
.
DetailsList
[
i
])
NewFlightList2
.
push
(
this
.
DetailsList
[
i
])
}
}
if
(
FlightList
.
length
==
this
.
DetailsList
.
length
-
1
){
for
(
let
i
=
0
;
i
<
FlightList2
.
length
;
i
++
){
let
DetailsList
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
DetailsList
))
DetailsList
.
forEach
((
x
,
index
)
=>
{
if
(
x
.
Arrival_time
&&
FlightList2
[
i
].
Arrival_time
){
DetailsList
.
slice
(
0
,
index
)
}
})
}
NewFlightList
=
[
FlightList
[
0
],
FlightList
[
FlightList
.
length
-
1
]]
if
(
FlightList
.
length
>
0
){
let
obj
=
{
FlightList
:
FlightList
,
NewFlightList
:
NewFlightList
,
...
...
@@ -445,7 +452,7 @@
this
.
NewDetailsList
.
push
(
obj
)
}
if
(
FlightList2
.
length
==
1
){
if
(
FlightList2
.
length
>
0
){
let
obj
=
{
FlightList
:
FlightList2
,
NewFlightList
:
NewFlightList2
,
...
...
pages/airTicket/TicketOrderList.vue
View file @
493f8d57
...
...
@@ -110,6 +110,7 @@
x
.
week
=
''
x
.
duration
=
''
x
.
frequency
=
0
x
.
frequencyA
=
0
x
.
different
=
0
//是否异地
x
.
NewFlightList
=
[]
x
.
loading
=
false
...
...
@@ -120,22 +121,34 @@
arr
(
x
.
flightList
)
})
res
.
data
.
pageData
.
forEach
(
x
=>
{
if
(
x
.
flightList
.
length
>
2
){
x
.
different
=
1
}
x
.
frequency
=
0
x
.
frequencyA
=
0
x
.
flightList
.
forEach
((
y
,
index
)
=>
{
if
(
y
.
flightSubType
!=
3
&&
x
.
flightList
.
length
>
2
){
x
.
frequency
+=
1
}
if
(
y
.
flightSubType
==
3
){
x
.
frequencyA
+=
1
}
let
date
=
y
.
flightDate
.
split
(
'-'
)
y
.
time
=
`
${
date
[
1
]}
-
${
date
[
2
]}
`
y
.
week
=
getDateWeek
(
y
.
flightDate
)
y
.
frequency
=
x
.
flightList
.
length
-
2
>
1
?
x
.
flightList
.
length
-
2
:
0
if
(
index
==
0
){
console
.
log
(
x
.
frequency
-
1
,
'-----frequency'
)
y
.
frequency
=
x
.
frequency
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
){
console
.
log
(
x
.
frequencyA
-
1
,
'-----frequencyA'
)
y
.
frequency
=
x
.
frequencyA
-
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
)
}
// x.NewFlightList[0].frequency = y.frequency
})
})
if
(
this
.
msg
.
pageIndex
===
1
)
{
...
...
pages/airTicket/airTicketDetails.vue
View file @
493f8d57
...
...
@@ -12,14 +12,16 @@
<view>
{{
NewDetailsList
[
0
].
DepartureName
}}
</view>
<img
class=
"inlineblock ML50 MR50"
mode=
"widthFix"
style=
"width: 79rpx;height: 38rpx"
src=
"https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1696990221000_663.png"
/>
<view>
{{
NewDetailsList
[
0
].
FlightList
[
NewDetailsList
[
0
].
FlightList
.
length
-
1
].
ArrivalCityName
}}
</view>
<view>
{{
NewDetailsList
[
0
].
FlightList
[
NewDetailsList
[
0
].
FlightList
.
length
-
1
].
ArrivalCityName
}}
</view>
</view>
<AirTicketDetails
v-if=
"NewDetailsList.length>0"
:DetailsList=
"NewDetailsList"
></AirTicketDetails>
<template
v-if=
"orderMsg.Unit_Price>0&&B2BSellNum>0"
>
<view
class=
"PX50 MT20 MB30 row-aic-n"
>
<img
class=
"inlineblock MR10"
mode=
"widthFix"
style=
"width: 167rpx;height: 31rpx"
src=
"https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1697021959000_719.png"
/>
<view
class=
"fz26 color1D1D20 ML31"
>
<view
class=
"fz26 color1D1D20 ML31"
v-if=
"orderMsg.ManNum>0||orderMsg.BabyNum>0||orderMsg.ChirdNum>0"
>
<text>
已选:
<!--
{{
orderMsg
.
GuestNum
}}
<text
class=
"fz22"
>
人
</text>
-->
</text>
...
...
@@ -458,7 +460,7 @@
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
//
y.frequency = this.DetailsList.length-2>1?this.DetailsList.length-2:0
})
let
FlightList
=
[]
let
NewFlightList
=
[]
...
...
@@ -466,17 +468,15 @@
let
NewFlightList2
=
[]
for
(
let
i
=
0
;
i
<
this
.
DetailsList
.
length
;
i
++
){
if
(
this
.
DetailsList
.
length
-
1
!=
i
){
if
(
this
.
DetailsList
[
i
].
FlightSubType
!=
3
){
FlightList
.
push
(
this
.
DetailsList
[
i
])
if
(
this
.
DetailsList
.
length
-
2
==
i
||
i
==
0
){
NewFlightList
.
push
(
this
.
DetailsList
[
i
])
}
}
else
{
FlightList2
.
push
(
this
.
DetailsList
[
i
])
NewFlightList2
.
push
(
this
.
DetailsList
[
i
])
}
}
if
(
FlightList
.
length
==
this
.
DetailsList
.
length
-
1
){
NewFlightList
=
[
FlightList
[
0
],
FlightList
[
FlightList
.
length
-
1
]]
if
(
FlightList
.
length
>
0
){
let
obj
=
{
FlightList
:
FlightList
,
NewFlightList
:
NewFlightList
,
...
...
@@ -485,7 +485,7 @@
this
.
NewDetailsList
.
push
(
obj
)
}
if
(
FlightList2
.
length
==
1
){
if
(
FlightList2
.
length
>
0
){
let
obj
=
{
FlightList
:
FlightList2
,
NewFlightList
:
NewFlightList2
,
...
...
pages/airTicket/airTicketList.vue
View file @
493f8d57
...
...
@@ -278,6 +278,7 @@
let
arr
=
function
(
list
){
list
.
forEach
(
x
=>
{
x
.
Price
=
0
x
.
frequency
=
0
})
}
arr
(
this
.
dataList
)
...
...
@@ -289,19 +290,36 @@
y
.
FlightList
.
forEach
(
z
=>
{
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 '
:
''
}
`
,
Days
:
1
,
...
z
}
y
.
NewFlightList
.
push
(
obj
)
})
}
else
if
(
y
.
FlightList
.
length
>
2
){
y
.
frequency
=
0
let
FlightDates
=
y
.
FlightList
.
map
(
z
=>
{
return
z
.
FlightDate
})
let
NewFlightDates
=
[]
let
Days
=
[]
if
(
FlightDates
&&
FlightDates
.
length
>
1
){
NewFlightDates
=
FlightDates
.
slice
(
0
,
FlightDates
.
length
-
1
)
Days
=
new
Set
(
NewFlightDates
)
}
y
.
FlightList
.
forEach
(
z
=>
{
if
(
z
.
FlightType
!=
3
){
y
.
frequency
+=
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
.
FlightList
.
length
-
2
>
1
?
y
.
FlightList
.
length
-
2
:
0
,
frequency
:
y
.
frequency
-
1
,
FlightType
:
y
.
FlightList
[
1
].
FlightType
,
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
:
1
,
...
y
.
FlightList
[
y
.
FlightList
.
length
-
1
]
}
y
.
NewFlightList
.
push
(
obj
)
...
...
@@ -317,9 +335,6 @@
});
this
.
NewDataList
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
dataList
))
this
.
StartDateObj
=
this
.
NewDateList
.
length
>
0
&&
this
.
NewDateList
.
length
==
1
?
this
.
NewDateList
[
0
]:{}
// this.NewDataList = this.dataList.filter(x=> {
// return x.FlightDate==this.NewDateList[0].times
// })
}
uni
.
hideLoading
()
});
...
...
pages/airTicket/components/TicketOrderDetails.vue
View file @
493f8d57
...
...
@@ -29,7 +29,7 @@
<view
class=
"row relative"
v-for=
"(item,index) in items.NewFlightList"
:class=
"[index==0?'MB50':'']"
>
<text
v-if=
"index==1"
class=
"fz18 fontWeight400 colorFF5858 absolute airTicketDetailsCard-timeT"
>
{{item.time}} 周{{item.week}}
{{item.time}} 周{{item.week}}
</text>
<view
class=
"airTicketDetailsCard-timeL column flexS MR20 textRight"
>
<view
v-if=
"index==0"
class=
"fz28 fontBold relative relativeFT10"
>
{{item.Departure_time}}
</view>
...
...
pages/airTicket/components/TicketOrderList.vue
View file @
493f8d57
...
...
@@ -31,7 +31,7 @@
<view
class=
"row-ajc-n"
>
<view
class=
"FlightDirection-zhuan z-index2 MB10"
>
<text
v-if=
"!childs.frequency"
class=
"fz20 color9999A5"
>
{{
childs
.
duration
}}
</text>
<text
v-
else
class=
"block bgECF1F4 fz21 nowrap"
>
<text
v-
if=
"childs.frequency"
class=
"block bgECF1F4 fz21 nowrap"
>
转
<template
v-if=
"childs.frequency>1"
>
+
{{
childs
.
frequency
}}
</
template
>
</text>
</view>
...
...
pages/airTicket/components/airTicketList.vue
View file @
493f8d57
...
...
@@ -6,7 +6,7 @@
<view
v-if=
"item.FlightList.length>2"
class=
"aviationCard-wf absolute bg111 colorFFF fz20 z-index2"
>
异地往返
</view>
<view
class=
"column flexG"
>
<view
:class=
"[i
tem.FlightList.length-1!=indexs?'MB30':'
']"
:class=
"[i
ndexs?'':'MB10
']"
v-for=
"(childs,indexs) in item.NewFlightList"
>
<view
class=
"row-sb-n MT25"
>
<view
class=
"flexS MR20"
>
...
...
@@ -50,18 +50,20 @@
<text
class=
"fz36 fontBold"
>
{{childs.Arrival_time}}
</text>
<text
class=
"fz22 MT5 width100 ellipsis1"
>
{{childs.aName}}
</text>
</view>
<
!-- <
view class="FlightDirection-time absolute colorFF5858 fz20 nowrap">
<view
class=
"FlightDirection-time absolute colorFF5858 fz20 nowrap"
>
<text>
+
</text>
<text class="ML5">
1
</text>
<text
class=
"ML5"
>
{{childs.Days}}
</text>
<text
class=
"ML5"
>
天
</text>
</view>
-->
</view>
</view>
</view>
<view
class=
"row-w MT15"
>
<view
class=
"aviationTitle row-aic-n"
>
<img
class=
"inlineblock"
mode=
"widthFix"
style=
"width: 36rpx;height: 30rpx;"
<view>
<img
class=
"inlineblock flexS"
mode=
"widthFix"
style=
"width: 36rpx;height: 30rpx;"
:src=
"item.AirlineUrl"
/>
</view>
<text
class=
"fz22 ML10 color9999A5"
>
{{item.AirLineName}}
</text>
</view>
</view>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment