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
b5d1a654
Commit
b5d1a654
authored
Mar 07, 2025
by
罗超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改BUG
parent
ecb232b4
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
53 additions
and
27 deletions
+53
-27
index.vue
pages/airTicket/components/guest/index.vue
+38
-17
jz_Reserve.vue
pages/jiuzhai/jz_Reserve.vue
+13
-1
jz_SureOrder.vue
pages/jiuzhai/jz_SureOrder.vue
+2
-9
No files found.
pages/airTicket/components/guest/index.vue
View file @
b5d1a654
...
@@ -14,7 +14,13 @@
...
@@ -14,7 +14,13 @@
</view>
</view>
<view
class=
"row items-center"
v-for=
"(x,i) in showGuests"
style=
"padding: 30rpx 0;"
>
<view
class=
"row items-center"
v-for=
"(x,i) in showGuests"
style=
"padding: 30rpx 0;"
>
<u-checkbox-group>
<u-checkbox-group>
<u-checkbox
:disabled=
"!x.Checked && !canChecked && x.year>1"
shape=
"circle"
v-model=
"x.Checked"
active-color=
"#B99846"
></u-checkbox>
<u-checkbox
:disabled=
"!x.Checked && !canChecked && x.year>1"
shape=
"circle"
v-model=
"x.Checked"
@
change=
"checkedChange"
active-color=
"#B99846"
></u-checkbox>
</u-checkbox-group>
</u-checkbox-group>
<view
class=
"col q-ml-md q-mr-md"
@
click=
"setCheckStatusHandle(x)"
>
<view
class=
"col q-ml-md q-mr-md"
@
click=
"setCheckStatusHandle(x)"
>
<view
class=
"row items-center"
>
<view
class=
"row items-center"
>
...
@@ -74,11 +80,7 @@
...
@@ -74,11 +80,7 @@
components
:{
GuestList
}
,
components
:{
GuestList
}
,
computed
:
{
computed
:
{
showGuests
()
{
showGuests
()
{
this
.
guests
.
forEach
(
x
=>
{
return
this
.
guests
.
filter
(
x
=>
x
.
Checked
||
x
.
Display
);
if
(
x
.
Checked
)
x
.
Display
=
true
}
)
const
r
=
this
.
guests
.
filter
(
x
=>
x
.
Display
)
return
r
}
,
}
,
crCount
(){
crCount
(){
const
r
=
this
.
guests
.
filter
(
x
=>
x
.
year
>=
12
&&
x
.
Checked
)
const
r
=
this
.
guests
.
filter
(
x
=>
x
.
year
>=
12
&&
x
.
Checked
)
...
@@ -115,25 +117,44 @@
...
@@ -115,25 +117,44 @@
}
,
}
,
created
()
{
created
()
{
if
(
uni
.
getStorageSync
(
'guest'
)){
if
(
uni
.
getStorageSync
(
'guest'
)){
this
.
guests
=
uni
.
getStorageSync
(
'guest'
).
filter
(
x
=>
x
.
Id
!=
''
)
//
this.guests = uni.getStorageSync('guest').filter(x=>x.Id!='')
this
.
guests
.
forEach
((
x
,
i
)
=>
{
// this.guests.forEach((x,i)=>
{
x
.
Checked
=
false
// x.Checked=false
x
.
Display
=
i
==
0
// x.Display=i==0
}
)
//
}
)
this
.
calcYearHandle
()
// this.calcYearHandle()
this
.
guests
=
uni
.
getStorageSync
(
'guest'
)
.
filter
(
x
=>
x
.
Id
!=
''
)
.
map
((
x
,
i
)
=>
({
...
x
,
Checked
:
false
,
Display
:
i
===
0
,
year
:
this
.
calculateAge
(
x
.
BirthDay
)
}
));
this
.
chosenGuest
=
this
.
guests
.
slice
(
0
,
1
)
this
.
chosenGuest
=
this
.
guests
.
slice
(
0
,
1
)
}
}
}
,
}
,
methods
:{
methods
:{
setCheckStatusHandle
(
x
){
setCheckStatusHandle
(
x
){
if
(
!
x
.
Checked
&&
!
this
.
canChecked
&&
x
.
year
>
1
)
return
//
if(!x.Checked && !this.canChecked && x.year>1) return
const
g
=
this
.
guests
.
find
(
t
=>
x
.
Id
==
t
.
Id
)
//
const g = this.guests.find(t=>x.Id==t.Id)
if
(
g
){
//
if(g)
{
g
.
Checked
=
!
g
.
Checked
//
g.Checked = !g.Checked
}
//
}
//console.log('setCheckStatusHandle',x.Checked)
//console.log('setCheckStatusHandle',x.Checked)
if
(
!
x
.
Checked
&&
!
this
.
canChecked
&&
x
.
year
>
1
)
return
;
const
index
=
this
.
guests
.
findIndex
(
t
=>
x
.
Id
===
t
.
Id
);
if
(
index
!==
-
1
)
{
// 使用 Vue.set 或替换整个对象确保响应性
this
.
$set
(
this
.
guests
,
index
,
{
...
this
.
guests
[
index
],
Checked
:
!
this
.
guests
[
index
].
Checked
,
Display
:
true
// 确保选中后显示在列表中
}
);
}
}
,
}
,
chosenListHandle
(){
chosenListHandle
(){
this
.
listVisible
=
true
this
.
listVisible
=
true
...
...
pages/jiuzhai/jz_Reserve.vue
View file @
b5d1a654
...
@@ -379,7 +379,7 @@
...
@@ -379,7 +379,7 @@
</view>
</view>
<view
class=
"jz_form"
style=
"margin: 40rpx 0; padding: 0"
>
<view
class=
"jz_form"
style=
"margin: 40rpx 0; padding: 0"
>
<view
class=
"form-items"
>
<view
class=
"form-items"
>
<view
class=
"label"
>
在线支付
</view>
<view
class=
"label"
>
商品总价
</view>
<view
class=
"val f14 regular"
style=
"text-align: right"
>
<view
class=
"val f14 regular"
style=
"text-align: right"
>
<text
style=
"margin-right: 30rpx"
>
{{
total
}}
人
</text>
<text
style=
"margin-right: 30rpx"
>
{{
total
}}
人
</text>
<text
class=
"red"
>
¥
{{
price
}}
</text>
<text
class=
"red"
>
¥
{{
price
}}
</text>
...
@@ -677,7 +677,14 @@
...
@@ -677,7 +677,14 @@
Income
:
0
,
Income
:
0
,
Refund
:
0
,
Refund
:
0
,
MallBaseId
:
this
.
userInfo
.
MallBaseId
,
MallBaseId
:
this
.
userInfo
.
MallBaseId
,
CreateBy
:
0
}
;
}
;
// #ifdef MP-DI
if
(
this
.
customer
.
salesBaseInfo
&&
this
.
customer
.
salesBaseInfo
.
employeeId
){
msg
.
CreateBy
=
this
.
customer
.
salesBaseInfo
.
employeeId
}
// #endif
this
.
apipost
(
"AddOrderInfo_post"
,
msg
,
(
res
)
=>
{
this
.
apipost
(
"AddOrderInfo_post"
,
msg
,
(
res
)
=>
{
if
(
res
.
resultCode
==
1
)
{
if
(
res
.
resultCode
==
1
)
{
this
.
orderInfo
=
JSON
.
parse
(
res
.
data
.
sPayInfo
)
this
.
orderInfo
=
JSON
.
parse
(
res
.
data
.
sPayInfo
)
...
@@ -1184,6 +1191,11 @@
...
@@ -1184,6 +1191,11 @@
// #endif
// #endif
orderForm
:
4
,
// 订单来源 4-小程序
orderForm
:
4
,
// 订单来源 4-小程序
}
;
}
;
// #ifdef MP-DI
if
(
this
.
customer
.
salesBaseInfo
&&
this
.
customer
.
salesBaseInfo
.
employeeId
){
msg
.
CreateBy
=
this
.
customer
.
salesBaseInfo
.
employeeId
}
// #endif
if
(
this
.
realCurrentPriceInfo
.
priceUnion
)
{
if
(
this
.
realCurrentPriceInfo
.
priceUnion
)
{
msg
.
DepartureCityId
=
this
.
realCurrentPriceInfo
.
priceUnion
.
unionCityId
msg
.
DepartureCityId
=
this
.
realCurrentPriceInfo
.
priceUnion
.
unionCityId
msg
.
IsIntermodal
=
1
msg
.
IsIntermodal
=
1
...
...
pages/jiuzhai/jz_SureOrder.vue
View file @
b5d1a654
...
@@ -446,17 +446,10 @@
...
@@ -446,17 +446,10 @@
</view>
</view>
<view
class=
"jz_form"
style=
"margin: 40rpx 0; padding: 0"
>
<view
class=
"jz_form"
style=
"margin: 40rpx 0; padding: 0"
>
<view
class=
"form-items"
>
<view
class=
"form-items"
>
<view
class=
"label"
>
在线支付
</view>
<view
class=
"label"
>
商品总价
</view>
<view
class=
"val f14 regular"
style=
"text-align: right"
>
<view
class=
"val f14 regular"
style=
"text-align: right"
>
<text
style=
"margin-right: 30rpx"
>
{{
orderData
.
model
.
GuestNum
}}
人
</text>
<text
style=
"margin-right: 30rpx"
>
{{
orderData
.
model
.
GuestNum
}}
人
</text>
<text
class=
"red"
>
¥
<text
class=
"red"
>
¥
{{
orderData
.
model
.
PreferPrice
}}
</text>
<template
v-if=
" orderData.model.DiscountMoney&&orderData.model.DiscountMoney>0"
>
{{
Number
(
orderData
.
model
.
PreferPrice
)
-
Number
(
orderData
.
model
.
DiscountMoney
)
}}
</
template
>
<
template
v-else
>
{{
orderData
.
model
.
PreferPrice
}}
</
template
>
</text>
</view>
</view>
</view>
</view>
<view
class=
"form-items"
style=
"border-bottom: none"
>
<view
class=
"form-items"
style=
"border-bottom: none"
>
...
...
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