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
0c6242aa
Commit
0c6242aa
authored
Feb 08, 2025
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增参数
parent
24124116
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
163 additions
and
147 deletions
+163
-147
TicketOrderList.vue
pages/airTicket/TicketOrderList.vue
+163
-147
No files found.
pages/airTicket/TicketOrderList.vue
View file @
0c6242aa
<
template
>
<view
class=
"bgF5"
:class=
"[dataList.length==0||3>dataList.length?'height100vh':'height100']"
>
<view
class=
"bgF5"
:class=
"[dataList.length==0||3>dataList.length?'height100vh':'height100']"
>
<view
class=
"TicketOrderList-header bgFFF fixed row-sb-n z-index3"
>
<view
v-for=
"(item,index) in TicketOrderTyle"
class=
"border1 hidden fz24 bgF5 textCenter"
:class=
"[msg.orderState==item.Id?'borderDEBF7B':'borderF5']"
<view
v-for=
"(item,index) in TicketOrderTyle"
class=
"border1 hidden fz24 bgF5 textCenter"
:class=
"[msg.orderState==item.Id?'borderDEBF7B':'borderF5']"
@
click=
"research(item.Id)"
>
{{
item
.
Name
}}
</view>
</view>
<u-empty
v-if=
"dataList.length==0"
text=
"暂无数据"
mode=
"data"
></u-empty>
<scroll-view
v-else
:scroll-y=
"true"
style=
"background-color: #f0f4f7;"
:enable-back-to-top=
"true"
:enable-flex=
"true"
<scroll-view
v-else
:scroll-y=
"true"
style=
"background-color: #f0f4f7;"
:enable-back-to-top=
"true"
:enable-flex=
"true"
@
scrolltolower=
"lower"
:style=
"
{ 'height': `calc(100% - ${scrollHeight})`}">
<view
class=
"TicketOrderListC"
>
<view
class=
"TicketOrderList-box"
>
<TicketOrderList
:dataList=
"dataList"
:msg=
"msg"
@
research=
"research"
></TicketOrderList>
</view>
<view
style=
"padding:10px 0;"
>
<u-loadmore
:status=
"status"
:load-text=
"loadText"
:font-size=
"24"
:margin-top=
"0"
:margin-bottom=
"0"
bg-color=
"#f0f4f7"
/>
<u-loadmore
:status=
"status"
:load-text=
"loadText"
:font-size=
"24"
:margin-top=
"0"
:margin-bottom=
"0"
bg-color=
"#f0f4f7"
/>
</view>
</view>
</scroll-view>
...
...
@@ -28,7 +22,9 @@
</
template
>
<
script
>
import
TicketOrderList
from
"./components/TicketOrderList.vue"
;
import
{
getDateWeek
}
from
"./dates.js"
;
import
{
getDateWeek
}
from
"./dates.js"
;
export
default
{
components
:
{
TicketOrderList
...
...
@@ -37,23 +33,34 @@
return
{
scrollTop
:
0
,
status
:
'loadmore'
,
msg
:
{
msg
:
{
pageIndex
:
1
,
pageSize
:
15
,
//MiniAppUserId: 0,
orderType
:
-
1
,
CustomerId
:
0
,
//客户ID
orderType
:
-
1
,
orderState
:
0
,
GroupType
:
5
,
//线路
订单
queryDays
:
0
,
OutBranchId
:
-
1
GroupType
:
5
,
//机票
订单
queryDays
:
0
,
OutBranchId
:
-
1
},
pageCount
:
0
,
dataList
:
[],
TicketOrderTyle
:[
{
Name
:
'全部订单'
,
Id
:
0
},
{
Name
:
'已付款'
,
Id
:
3
},
{
Name
:
'待付款'
,
Id
:
1
},
{
Name
:
'已取消'
,
Id
:
4
},
TicketOrderTyle
:
[{
Name
:
'全部订单'
,
Id
:
0
},
{
Name
:
'已付款'
,
Id
:
3
},
{
Name
:
'待付款'
,
Id
:
1
},
{
Name
:
'已取消'
,
Id
:
4
},
],
loadText
:
{
loadmore
:
"轻轻上拉,加载更多"
,
...
...
@@ -61,10 +68,13 @@
nomore
:
"没有更多了"
,
},
scrollHeight
:
'30px'
,
b2b_user_info
:
{},
}
},
onLoad
(
options
){
this
.
msg
.
orderState
=
options
.
orderState
?
options
.
orderState
:
0
onLoad
(
options
)
{
this
.
msg
.
orderState
=
options
.
orderState
?
options
.
orderState
:
0
;
this
.
b2b_user_info
=
uni
.
getStorageSync
(
'b2b_user'
);
this
.
msg
.
CustomerId
=
this
.
b2b_user_info
.
customerId
;
},
created
()
{},
onShow
()
{
...
...
@@ -104,8 +114,8 @@
this
.
msg
,
(
res
)
=>
{
if
(
res
.
resultCode
==
1
)
{
let
arr
=
function
(
list
)
{
list
.
forEach
(
x
=>
{
let
arr
=
function
(
list
)
{
list
.
forEach
(
x
=>
{
x
.
time
=
''
x
.
week
=
''
x
.
duration
=
''
...
...
@@ -116,33 +126,35 @@
})
}
arr
(
res
.
data
.
pageData
)
res
.
data
.
pageData
.
forEach
(
x
=>
{
res
.
data
.
pageData
.
forEach
(
x
=>
{
arr
(
x
.
flightList
)
})
res
.
data
.
pageData
.
forEach
(
x
=>
{
if
(
x
.
flightList
.
length
>
2
)
{
res
.
data
.
pageData
.
forEach
(
x
=>
{
if
(
x
.
flightList
.
length
>
2
)
{
x
.
different
=
1
}
let
FlightList
=
x
.
flightList
.
filter
(
z
=>
{
return
z
.
flightSubType
!=
3
let
FlightList
=
x
.
flightList
.
filter
(
z
=>
{
return
z
.
flightSubType
!=
3
})
let
FlightList2
=
x
.
flightList
.
filter
(
z
=>
{
return
z
.
flightSubType
==
3
let
FlightList2
=
x
.
flightList
.
filter
(
z
=>
{
return
z
.
flightSubType
==
3
})
x
.
flightList
.
forEach
((
y
,
index
)
=>
{
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
=
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 '
:
''
}
`
if
(
index
==
0
)
{
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
=
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 '
:
''
}
`
if
(
x
.
flightList
.
length
-
1
==
index
)
{
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
)
}
})
...
...
@@ -153,7 +165,7 @@
this
.
dataList
=
this
.
dataList
.
concat
(
res
.
data
.
pageData
);
}
this
.
pageCount
=
res
.
data
.
pageCount
;
if
(
this
.
pageCount
==
1
)
this
.
status
=
"nomore"
;
if
(
this
.
pageCount
==
1
)
this
.
status
=
"nomore"
;
}
uni
.
hideLoading
()
}
...
...
@@ -173,24 +185,28 @@
}
</
script
>
<
style
scoped
>
@import
url("@/asset/css/flex.css")
;
@import
url("./style.css")
;
.TicketOrderList-header
{
@import
url("@/asset/css/flex.css")
;
@import
url("./style.css")
;
.TicketOrderList-header
{
left
:
0
;
right
:
0
;
top
:
0
;
padding
:
27
rpx
54
rpx
;
}
.TicketOrderList-header
>
view
{
}
.TicketOrderList-header
>
view
{
width
:
135
rpx
;
padding
:
15
rpx
0
;
border-radius
:
20
rpx
;
}
.TicketOrderListC
{
}
.TicketOrderListC
{
padding-top
:
145
rpx
;
}
.TicketOrderList-box
{
}
.TicketOrderList-box
{
padding
:
0
54
rpx
;
padding-bottom
:
49
rpx
;
}
}
</
style
>
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