Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
jijin
/
dance-pc
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
8b639c6f
authored
2025-05-24 16:31:48 +0800
by
华明祺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
no message
1 parent
f8237179
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
428 additions
and
457 deletions
src/apiPc/booking.js
src/routerPc/en.js
src/viewsPc/booking/pay.vue
src/viewsPc/booking/ticket/confirmOrder.vue
src/viewsPc/booking/ticket/index.vue
src/viewsPc/booking/ticket/peopleManage.vue
vite.config.js
src/apiPc/booking.js
View file @
8b639c6
...
...
@@ -511,6 +511,22 @@ export function getTicketInfoByActivityId(params) {
})
}
export
function
getActivityTypeVoById
(
params
)
{
return
request
({
url
:
`/ota/activityType/getActivityTypeVoById`
,
method
:
'get'
,
params
})
}
export
function
getListByAtstId
(
params
)
{
return
request
({
url
:
`/ota/activitySeat/getListByAtstId`
,
method
:
'get'
,
params
})
}
// 根据赛事ID获取票档
export
function
getTicketListApi
(
params
)
{
return
request
({
...
...
@@ -538,6 +554,22 @@ export function listApi(params) {
})
}
export
function
getStadiumList
(
params
)
{
return
request
({
url
:
`/ota/activityStadium/getStadiumList`
,
method
:
'get'
,
params
})
}
export
function
getActivityTypeVoListByLatsId
(
params
)
{
return
request
({
url
:
`/ota/activityType/getActivityTypeVoListByLatsId`
,
method
:
'get'
,
params
})
}
// 获取当前用户的观影人列表
export
function
customerListApi
(
params
)
{
return
request
({
...
...
src/routerPc/en.js
View file @
8b639c6
...
...
@@ -362,7 +362,7 @@ export const constantRoutes = [
meta
:
{
title
:
'Ticket Booking'
}
},
{
path
:
'ticket/:activeId/:lat
Id/:at
tId'
,
path
:
'ticket/:activeId/:lat
s
tId'
,
component
:
()
=>
import
(
'@/viewsPc/booking/ticket/confirmOrder.vue'
),
name
:
'confirmOrder'
,
meta
:
{
title
:
'confirmOrder'
}
...
...
src/viewsPc/booking/pay.vue
View file @
8b639c6
...
...
@@ -124,42 +124,12 @@
{{
matchForm
.
address
}}
</el-col>
<el-col>
{{
form
?.
extJson
?.
ticketType
?.
name
}}
:
{{
form
?.
extJson
?.
num
}}{{
language
==
0
?
'张'
:
'Tickets'
}}
{{
form
?.
extJson
?.
atName
}}
{{
form
?.
extJson
?.
atsName
}}
{{
form
?.
extJson
?.
sessionType
==
'1000'
?
'日间场'
:
'夜间场'
}}
{{
form
?.
extJson
?.
ticketName
}}
{{
form
?.
num
}}{{
language
==
0
?
'张'
:
'Tickets'
}}
</el-col>
<el-col>
{{
language
==
0
?
'时间'
:
'Time'
}}
:
{{
dayjs
(
form
?.
extJson
?.
ticketDate
?.
ticketStart
).
format
(
'YYYY-MM-DD'
)
}}{{
form
.
extJson
?.
ticketDate
?.
ticketType
==
1
?
'~'
+
dayjs
(
form
?.
extJson
?.
ticketDate
?.
ticketEnd
).
format
(
'YYYY-MM-DD'
)
:
''
}}
</el-col>
<el-col
v-if=
"form?.extJson?.ticketDate?.isCountSale==1"
>
{{
language
==
0
?
`满${form?.extJson?.ticketDate.counts
}
人优惠`
:
`Discount for up to ${form?.extJson?.ticketDate.counts
}
people`
}}
<
span
v
-
if
=
"language == 0"
>
{{
form
?.
extJson
?.
ticketDate
.
discount
}}
折
<
/span
>
<
span
v
-
else
>
{{
(
10
-
form
?.
extJson
?.
ticketDate
.
discount
)
*
10
+
'%'
}}
off
<
/span
>
<
/el-col
>
<!--
<
el
-
col
>-->
<!--
{{
-->
<!--
language
==
0
?
'原价票'
:
'Cost Ticket'
-->
<!--
}}
:
{{
-->
<!--
language
==
0
?
form
?.
extJson
?.
ticketDate
?.
price
:
form
?.
extJson
?.
ticketDate
?.
priceEn
-->
<!--
}}
{{
language
==
0
?
'元'
:
'Euro'
}}
x
1
-->
<!--
{{
language
==
0
?
'张'
:
'Tickets'
}}
-->
<!--
<
/el-col>--
>
<!--
<
el
-
col
>-->
<!--
{{
-->
<!--
language
==
0
?
'优惠票'
:
'Concession Ticket'
-->
<!--
}}
:
{{
-->
<!--
language
==
0
?
form
?.
extJson
?.
ticketDate
?.
rebatePrice
:
form
?.
extJson
?.
ticketDate
?.
rebatePriceEn
-->
<!--
}}
{{
language
==
0
?
'元'
:
'Euro'
}}
x
1
-->
<!--
{{
language
==
0
?
'张'
:
'Tickets'
}}
-->
<!--
<
/el-col>--
>
</el-row>
</div>
</div>
...
...
@@ -179,9 +149,9 @@
</el-row>
</div>
</div>
<div
class=
"leftboderTT"
>
{{
language
==
0
?
'预订信息'
:
'Booking information'
}}
</div>
<div
class=
"border-info mt20"
>
<el-row
v-if=
"type == 'hotel'"
>
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
...
...
@@ -203,12 +173,12 @@
<!--
<el-tag
class=
"mr10"
>
{{
car
.
carSeat
}}
{{
language
==
0
?
'座 '
:
'Sets'
}}
</el-tag>
-->
<!--
<el-tag>
{{
car
.
carColor
}}
</el-tag>
-->
<!--
</div>
-->
<!--
<span
v-if=
"car.num > 0"
>
{{
car
.
num
}}{{
-->
<!--
language
==
0
?
'辆'
:
'Cars'
-->
<!--
}}
*
{{
language
==
0
?
'¥'
:
'€'
}}{{
car
.
price
}}
</span>
-->
<!--
</div>
-->
<div>
{{
language
==
0
?
'人数'
:
'People'
}}
:
{{
form
.
pickUpBo
.
count
}}
</div>
<div>
{{
language
==
0
?
'航班/火车班次'
:
'Flight/Train'
}}
:
{{
form
.
pickUpBo
.
no
}}
</div>
<div>
{{
language
==
0
?
'接机/接站地点'
:
'Pick-up/Drop-off Place'
}}
:
...
...
@@ -295,54 +265,40 @@
<el-col
:span=
"24"
>
{{
language
==
0
?
'备注'
:
'Remarks'
}}
:
{{
form
.
remarks
}}
</el-col>
</el-row>
<el-row
v-if=
"type == 'ticket'"
style=
"width: 100%"
>
<
el
-
row
v
-
for
=
"
v in form.extJson?.message
"
style
=
"width: 100%"
>
<el-row
v-for=
"
(v,i) in form.extJson?.orderCustomerList"
:key=
"i
"
style=
"width: 100%"
>
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
<div>
{{
v
.
name
}}
</div>
</el-col>
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
<!--
<
div
>
{{
-->
<!--
!
v
.
discount
?
language
==
0
?
'原价票'
:
'Cost Ticket'
:
language
==
0
?
'优惠票'
:
'Concession Ticket'
-->
<!--
}}
-->
<!--
<
/div>--
>
<div>
{{
v
.
idCard
}}
</div>
</el-col>
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
<div
v-if=
"language == 0 "
>
{{
language
==
0
?
'¥'
:
'€'
}}
{{
!
v
.
discount
?
form
.
extJson
?.
ticketDate
?.
price
:
form
.
extJson
?.
ticketDate
?.
rebatePrice
}}
/{{ language == 0
?
'张' : 'Tickets'
}}
¥
{{
form
.
price
}}
/张
</div>
<div
v-else
>
{{
language
==
0
?
'¥'
:
'€'
}}
{{
!
v
.
discount
?
form
.
extJson
?.
ticketDate
?.
priceEn
:
form
.
extJson
?.
ticketDate
?.
rebatePriceEn
}}
/{{ language == 0
?
'张' : 'Tickets'
}}
€
{{
form
.
priceEn
}}
/Tickets
</div>
</el-col>
</el-row>
<el-row
style=
"width: 100%"
>
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
<
div
>
{{
language
==
0
?
'购票数量'
:
'Number of tickets purchased'
}}
:
{{
form
.
num
}}
{{
language
==
0
?
'张'
:
'Tickets'
}}
<div>
{{
language
==
0
?
'购票数量'
:
'Number of tickets purchased'
}}
:
{{
form
.
num
}}{{
language
==
0
?
'张'
:
'Tickets'
}}
</div>
</el-col>
<
el
-
col
:
lg
=
"8"
:
md
=
"12"
:
sm
=
"12"
:
xs
=
"24"
>
{{
language
==
0
?
'联系方式'
:
'Contact Information'
}}
:
{{
form
.
phone
}}
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
{{
language
==
0
?
'联系方式'
:
'Contact Information'
}}
:
{{
form
.
phone
}}
</el-col>
<el-col
:lg=
"8"
:md=
"12"
:sm=
"12"
:xs=
"24"
>
{{
language
==
0
?
'共计'
:
'total'
}}
:{{
language
==
0
?
'¥'
:
'€'
{{
form
.
paymentType
==
'1'
?
'共计'
:
'total'
}}
:
{{
form
.
paymentType
==
'1'
?
'¥'
:
'€'
}}{{
Number
(
totalFee
).
toFixed
(
2
)
}}
</el-col>
</el-row>
</el-row>
<el-row
v-if=
"type == 'travel'"
style=
"width: 100%"
>
<el-row
v-for=
"(v,i) in form.personArr"
:key=
"i"
style=
"width: 100%"
>
...
...
@@ -376,10 +332,10 @@
}}{{
Number
(
totalFee
).
toFixed
(
2
)
}}
</el-col>
</el-row>
</el-row>
</div>
<el-row
align=
"middle"
justify=
"space-between"
>
<el-col
:lg=
"12"
>
<div
v-if=
"form.payDate"
>
{{
language
==
0
?
'支付时间'
:
'Payment Time'
}}
:
{{
form
.
payDate
}}
</div>
...
...
@@ -407,31 +363,7 @@
</div>
</el-col>
<el-col
:lg=
"24"
>
<
div
class
=
"text-center"
>
<!--
<
el
-
button
-->
<!--
v
-
if
=
"(form.viewStatus=='1'||form.viewStatus=='5')&&type == 'hotel'"
class
=
"mt20 btn-lineG"
-->
<!--
round
-->
<!--
size
=
"large"
type
=
"primary"
-->
<!--
@
click
=
"exportPdf"
-->
<!--
>-->
<!--
<
el
-
icon
>-->
<!--
<
Upload
/>-->
<!--
<
/el-icon>--
>
<!--
{{
language
==
0
?
'导出酒店预订单'
:
'Export PDF'
}}
-->
<!--
<
/el-button>--
>
<!--
<
el
-
button
-->
<!--
v
-
if
=
"(form.viewStatus=='1'||form.viewStatus=='5')&&(type=='makeUp'||type=='hotel'||type=='ticket')"
-->
<!--
class
=
"mt20 btn-lineG"
round
-->
<!--
size
=
"large"
-->
<!--
type
=
"primary"
-->
<!--
@
click
=
"downInvoice"
-->
<!--
>-->
<!--
<
el
-
icon
>-->
<!--
<
Download
/>-->
<!--
<
/el-icon>--
>
<!--
{{
language
==
0
?
'下载收据'
:
'DownLoad Invoice'
}}
-->
<!--
<
/el-button>--
>
<
/div
>
<div
class=
"text-center"
/>
</el-col>
</el-row>
</div>
...
...
@@ -445,9 +377,9 @@
{{
language
==
0
?
'登录后查看明细'
:
'View detailed information after logging in'
}}
</el-button>
</div>
<div
v-if=
"form.viewStatus == '0'&&(form.surplus!='0,0'&&form.surplus!='0')"
class=
"pd20"
>
<div
class=
"leftboderTT"
>
{{
language
==
0
?
'选择支付方式'
:
'Choose payment method'
}}
</div>
<div
class=
"mt20"
>
<el-radio-group
v-model=
"payType"
>
...
...
@@ -547,7 +479,7 @@
</el-button>
</el-col>
</el-row>
<div
v-if=
"form.payDate&&form.viewStatus=='1'"
>
<div
class=
"text-center"
>
<el-icon
color=
"#32B16C"
size=
"80"
>
...
...
@@ -559,7 +491,7 @@
</div>
</el-card>
</div>
<div
v-if=
"errorBox"
class=
"box"
>
<el-result
:sub-title=
"language==0?'请确认订单号是否正确':'Please confirm if the order number is correct'"
...
...
@@ -574,7 +506,7 @@
</el-result>
</div>
<Dialog
ref=
"DialogRef"
/>
<el-dialog
v-model=
"showSJDialog"
:close-on-click-modal=
"false"
:close-on-press-escape=
"false"
:title=
"language==0?'开收据':'Issue a receipt'"
width=
"460px"
...
...
@@ -764,19 +696,15 @@ async function getTicketOrderInfoFN() {
form
.
value
=
res
.
data
form
.
value
.
extJson
=
JSON
.
parse
(
form
.
value
.
extJson
)
try
{
form
.
value
.
extJson
.
ticketDate
=
JSON
.
parse
(
form
.
value
.
extJson
.
ticketDate
)
form
.
value
.
extJson
.
ticketType
=
JSON
.
parse
(
form
.
value
.
extJson
.
ticketType
)
form
.
value
.
extJson
.
message
=
JSON
.
parse
(
form
.
value
.
extJson
.
message
)
await
getDetail
(
form
.
value
.
extJson
.
ticketDate
.
activityId
)
matchId
.
value
=
form
.
value
.
extJson
.
ticketDate
.
activityId
await
getDetail
(
form
.
value
.
activeId
)
matchId
.
value
=
form
.
value
.
activeId
totalFee
.
value
=
language
.
value
==
0
?
form
.
value
.
total
:
form
.
value
.
totalEn
}
catch
(
e
)
{
console
.
log
(
e
)
}
finally
{
}
console
.
log
(
form
.
value
)
}
async
function
getDetail
(
activeId
)
{
...
...
@@ -1010,7 +938,7 @@ const showSJ = () => {
// proxy.download(`/ota/norder/getReceipt/${obj.orderId}`, {
// ...obj
// }, `Receipt_${new Date().getTime()}.pdf`)
// 报名
proxy
.
download
(
`/ota/norder/getReceipt/
${
obj
.
orderId
}
`
,
{
...
obj
...
...
@@ -1061,27 +989,27 @@ const showSJ = () => {
width
:
100%
;
max-width
:
1000px
;
margin
:
20px
auto
;
.head
{
background
:
#EFF2F7
;
height
:
50px
;
font-size
:
16px
;
font-weight
:
400
;
}
th
{
background
:
#FAFBFD
;
font-size
:
14px
;
border-bottom
:
1px
solid
#E5E5E5
;
border-right
:
1px
solid
#E5E5E5
;
}
td
{
border-bottom
:
1px
solid
#E5E5E5
;
border-right
:
1px
solid
#E5E5E5
;
padding
:
10px
;
}
&
.table-border
{
border-top
:
1px
solid
#E5E5E5
;
border-left
:
1px
solid
#E5E5E5
;
...
...
@@ -1100,23 +1028,23 @@ const showSJ = () => {
.result
{
font-size
:
22px
;
.flex
{
display
:
flex
;
align-items
:
center
;
font-weight
:
500
;
img
{
margin-right
:
10px
}
}
.priceb
{
color
:
#7B7F83
;
font-size
:
16px
;
text-align
:
right
;
line-height
:
50px
;
span
{
font-weight
:
bold
;
font-size
:
22px
;
...
...
@@ -1129,7 +1057,7 @@ const showSJ = () => {
.skeletonBox
{
position
:
relative
;
overflow
:
hidden
;
.btn-lineG
{
position
:
absolute
;
left
:
0
;
...
...
@@ -1139,7 +1067,7 @@ const showSJ = () => {
bottom
:
0
;
width
:
200px
;
box-shadow
:
0
0
1000px
500px
rgba
(
255
,
255
,
255
,
0.5
);
}
}
...
...
@@ -1151,26 +1079,26 @@ const showSJ = () => {
.priceBar
{
padding
:
0
0
20px
;
.flex
{
display
:
flex
;
justify-content
:
right
;
align-items
:
baseline
;
.item
{
font-size
:
16px
;
margin-right
:
15px
;
label
{
color
:
#95A1A6
;
}
span
{
font-family
:
DIN
Alternate
;
}
}
}
.size26
{
font-size
:
26px
;
}
...
...
src/viewsPc/booking/ticket/confirmOrder.vue
View file @
8b639c6
...
...
@@ -12,9 +12,18 @@
<div
class=
"address"
>
{{
TickForm
.
address
}}
</div>
</div>
<div
class=
"info"
>
<div
class=
"name"
>
{{
TickForm2
.
ticketTypeName
}}
</div>
<div
class=
"address"
>
{{
TickForm2
.
stadiumName
}}
</div>
<div
class=
"address"
>
{{
TickForm2
.
sessionType
==
'1000'
?
'日间场'
:
'夜间场'
}}
</div>
<div
class=
"address"
>
{{
TickForm2
.
ticketName
}}
</div>
<div
class=
"address"
>
剩余数量:
{{
(
TickForm2
.
limitCount
||
0
)
-
(
TickForm3
.
counts
||
0
)
}}
</div>
</div>
<div
class=
"ticket_info mb20"
>
<div
class=
"tit_box"
>
<div
class=
"line"
></div
>
<div
class=
"line"
/
>
<div
class=
"txt"
>
{{
languageFormat
(
language
,
"订票信息"
,
"Ticket Info"
)
}}
</div>
...
...
@@ -22,17 +31,17 @@
<div
class=
"form"
>
<el-form
ref=
"formRef"
:model=
"orderForm"
:rules=
"rules"
label-width=
"120px"
>
<!--
<el-form-item-->
<!-- :label="language == 0 ? '联系人' : 'contact'" prop="contacts"-->
<!-- >-->
<!--
<el-input-->
<!-- v-model="orderForm.contacts"-->
<!-- :placeholder=" language == 0 ? '请输入联系人' : 'Please enter the contact'"-->
<!-- style="width: 320px"-->
<!-- />-->
<!--
</el-form-item>
-->
<el-form-item
:label=
"language == 0 ? '联系人电话' : 'contact phone'"
prop=
"phone"
:label=
"language == 0 ? '联系人' : 'contact person'"
prop=
"contacts"
>
<el-input
v-model=
"orderForm.contacts"
:placeholder=
" language == 0 ? '请输入联系人' : 'Please enter the contact person'"
style=
"width: 320px"
/>
</el-form-item>
<el-form-item
:label=
"language == 0 ? '联系电话' : 'contact phone'"
prop=
"phone"
>
<el-input
v-model=
"orderForm.phone"
...
...
@@ -40,23 +49,24 @@
style=
"width: 320px"
/>
</el-form-item>
<el-form-item
:label=
"language == 0 ? '观看人' : 'Viewer'"
prop=
"
message
"
>
<el-form-item
:label=
"language == 0 ? '观看人' : 'Viewer'"
prop=
"
customerIds
"
>
<div
class=
"p_box"
>
<div
class=
"people"
>
<el-checkbox-group
v-model=
"orderForm.
message
"
@
change=
"changeGroup"
>
<el-checkbox-group
v-model=
"orderForm.
customerIds
"
@
change=
"changeGroup"
>
<div
v-for=
"(it, index) in personnelList"
:key=
"index"
class=
"prople_item"
>
v-for=
"(it, index) in personnelList"
:key=
"index"
class=
"prople_item"
>
<div>
<div
class=
"name"
>
{{
it
.
name
}}
<
span
v-if=
"it.discount"
class=
"tag_t p-right"
>
{{
language
==
0
?
'优惠'
:
'Discounts'
}}
</span
>
<
!--
<span
v-if=
"it.discount"
class=
"tag_t p-right"
>
{{
-->
<!--
language
==
0
?
'优惠'
:
'Discounts'
-->
<!--
}}
</span>
--
>
</div>
<div
class=
"idcard"
>
{{
it
.
idCard
}}
</div>
</div>
<el-checkbox
:
disabled=
"!it.pay ||(orderForm.message.length==5&&!orderForm.message.some(v=>v.id==it.id))
"
:value=
"it"
/>
:
value=
"it.id
"
/>
</div>
</el-checkbox-group>
</div>
...
...
@@ -72,7 +82,7 @@
<el-col
:lg=
"8"
class=
"right"
>
<div
class=
"tit_box"
>
<div
class=
"line"
></div
>
<div
class=
"line"
/
>
<div
class=
"txt"
>
{{
languageFormat
(
language
,
"订单明细"
,
"Order summary"
)
}}
</div>
...
...
@@ -81,44 +91,15 @@
<div
class=
"detail"
>
<div
class=
"detail_top"
>
<div
class=
"time"
>
{{
tickType
.
name
}}
<span
v-if=
"tickType.ticketType == 1"
class=
"tag_t"
>
{{
languageFormat
(
language
,
"套票"
,
"Package ticket"
)
}}
</span>
</div>
<p>
{{
language
==
0
?
'原价票'
:
'Cost Ticket'
}}
</p>
<div
class=
"ticket detail_top"
>
{{
language
==
0
?
tickType
.
price
:
tickType
.
priceEn
}}
<span>
{{
language
==
0
?
'元'
:
'Euro'
}}
</span>
{{
languageFormat
(
language
,
"票档"
,
"Ticket file"
)
}}
x
{{
customerArr_q
.
length
}}
{{
languageFormat
(
language
,
"张"
,
"tickets"
)
}}
{{
language
==
0
?
'票价'
:
'Cost Ticket'
}}
</div>
<p
>
{{
language
==
0
?
'优惠票'
:
'Concession Ticket'
}}
</p
>
<p
/
>
<div
class=
"ticket"
>
{{
language
==
0
?
tickType
.
rebatePrice
:
tickType
.
rebateP
riceEn
}}
{{
language
==
0
?
TickForm2
.
price
:
TickForm2
.
p
riceEn
}}
<span>
{{
language
==
0
?
'元'
:
'Euro'
}}
</span>
{{
languageFormat
(
language
,
"票档"
,
"Ticket file"
)
}}
x
{{
customerArr_b
.
length
}}
x
{{
orderForm
.
customerIds
.
length
}}
{{
languageFormat
(
language
,
"张"
,
"tickets"
)
}}
</div>
<div
v-if=
"tickType.isCountSale == 1"
style=
"border-top: 1px solid #dcdfe6;margin-top: 20px"
>
<p>
{{
language
==
0
?
`满${tickType.counts
}
人优惠`
:
`Discount for up to ${tickType.counts
}
people`
}}
<
/p
>
<
div
class
=
"ticket"
>
<
div
v
-
if
=
"language==0"
style
=
"color: orange;font-weight: 600"
>
{{
tickType
.
discount
}}
折
<
/div
>
<
div
v
-
else
style
=
"color: orange;font-weight: 600"
>
{{
(
10
-
tickType
.
discount
)
*
10
+
'%'
}}
off
<
/div
>
<
/div
>
<
/div
>
</div>
<div
class=
"detail_b"
>
<div
class=
"sum_txt"
>
...
...
@@ -126,16 +107,7 @@
</div>
<div
class=
"price_num"
>
<span>
{{
language
==
0
?
"¥"
:
"€"
}}
</span>
{{
language
==
0
?
(
price
.
total_cn
*
1
).
toFixed
(
2
)
:
(
price
.
total_en
*
1
).
toFixed
(
2
)
}}
<
span
v
-
if
=
"tickType.isCountSale==1&&orderForm.message.length>=tickType.counts"
class
=
"total"
>
{{
language
==
0
?
"¥"
:
"€"
}}
{{
language
==
0
?
(
price
.
total_cnY
*
1
).
toFixed
(
2
)
:
(
price
.
total_enY
*
1
).
toFixed
(
2
)
}}
<
/span
>
{{
((
language
==
0
?
TickForm2
.
price
:
TickForm2
.
priceEn
)
*
orderForm
.
customerIds
.
length
).
toFixed
(
2
)
}}
</div>
</div>
</div>
...
...
@@ -144,13 +116,13 @@
</div>
<div
class=
"footer"
>
<div>
<
span
class
=
"label"
>
{{
languageFormat
(
language
,
"共计金额"
,
"Subtotal"
)
}}
:
<
/span
>
<span
class=
"label"
>
{{
languageFormat
(
language
,
"共计金额"
,
"Subtotal"
)
}}
:
</span>
<span
class=
"value"
>
<
span
>
{{
language
==
0
?
"¥"
:
"€"
}}
<
/span
>
{{
language
==
0
?
(
price
.
total_cn
*
1
).
toFixed
(
2
)
:
(
price
.
total_en
*
1
).
toFixed
(
2
)
}}
<
/span
>
<span>
{{
language
==
0
?
"¥"
:
"€"
}}
</span>
{{
((
language
==
0
?
TickForm2
.
price
:
TickForm2
.
priceEn
)
*
orderForm
.
customerIds
.
length
).
toFixed
(
2
)
}}
</span>
</div>
<div
class=
"pay"
@
click=
"paymentHandle"
>
{{
languageFormat
(
language
,
"立即支付"
,
"Pay Now"
)
}}
...
...
@@ -163,124 +135,82 @@
</
template
>
<
script
setup
>
import
{
ref
,
computed
}
from
'vue'
import
{
ref
,
computed
,
onMounted
}
from
'vue'
import
{
customerListApi
,
getTicketTotalApi
,
submitOrderTicket
,
listApi
,
getTicketListApi
,
getTicketInfoByActivityId
,
getTicketInfoByActivityId
,
getActivityTypeVoById
,
getListByAtstId
}
from
'@/apiPc/booking'
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
{
languageFormat
}
from
"@/viewsPc/seat/utils/language.js"
;
import
useUserStore
from
"/@/store/modules/user"
;
import
{
useStorage
}
from
"@vueuse/core/index"
;
import
{
ElMessage
,
ElMessageBox
}
from
'element-plus'
import
{
languageFormat
}
from
'@/viewsPc/seat/utils/language.js'
import
useUserStore
from
'/@/store/modules/user'
import
{
useStorage
}
from
'@vueuse/core/index'
import
_
from
'lodash'
import
{
useRoute
,
useRouter
}
from
'vue-router'
const
useStore
=
useUserStore
()
const
user
=
computed
(()
=>
useUserStore
().
user
)
const
language
=
useStorage
(
'language'
,
0
)
console
.
log
(
language
)
const
loading
=
ref
(
false
);
const
route
=
useRoute
();
const
router
=
useRouter
();
const
order
=
ref
({
data
:
{
}
}
)
const
payment
=
ref
({
}
)
const
props
=
defineProps
({
activityId
:
[
String
,
Number
],
}
);
const
form
=
ref
({
}
)
const
loading
=
ref
(
false
)
const
route
=
useRoute
()
const
router
=
useRouter
()
const
personnelList
=
ref
([])
const
customerArr_q
=
ref
([])
//全票人
const
customerArr_b
=
ref
([])
//优惠票人
const
orderForm
=
ref
({
activeId
:
route
.
params
.
activeId
,
atId
:
route
.
params
.
latId
,
attId
:
route
.
params
.
attId
,
ticketDate
:
null
,
ticketType
:
null
,
phone
:
null
,
customerList
:
[],
//人员ids列表
message
:
[],
//完整的人员列表
num
:
0
,
total
:
null
}
)
const
price
=
ref
({
total_en
:
0
,
total_cn
:
0
,
total_enY
:
0
,
total_cnY
:
0
,
customerIds
:
[]
})
const
tickType
=
ref
({
}
)
const
matchType
=
ref
({
}
)
const
rules
=
ref
({
contacts
:
[
{
required
:
true
,
message
:
languageFormat
(
language
.
value
,
"请输入联系人"
,
"Please enter the contact person"
),
trigger
:
"blur"
}
,
message
:
languageFormat
(
language
.
value
,
'请输入联系人'
,
'Please enter the contact person'
),
trigger
:
'blur'
}
],
phone
:
[
{
required
:
true
,
message
:
languageFormat
(
language
.
value
,
"请输入联系电话"
,
"Please enter the contact phone number"
),
trigger
:
"blur"
}
,
message
:
languageFormat
(
language
.
value
,
'请输入联系电话'
,
'Please enter the contact phone number'
),
trigger
:
'blur'
}
],
message
:
[
customerIds
:
[
{
required
:
true
,
message
:
languageFormat
(
language
.
value
,
"请选择观众"
,
"Please select the audience"
),
trigger
:
"blur"
}
,
]
,
message
:
languageFormat
(
language
.
value
,
'请选择观看人'
,
'Please select the audience'
),
trigger
:
'change'
}
]
})
const
formRef
=
ref
(
null
)
const
TickForm
=
ref
({})
let
timer
=
null
;
const
TickForm2
=
ref
({})
const
TickForm3
=
ref
({})
customerList
()
onMounted
(()
=>
{
customerList
()
getDetail
()
function
changeGroup
(
e
)
{
if
(
orderForm
.
value
.
message
.
length
==
6
)
{
ElMessageBox
.
confirm
(
language
.
value
==
0
?
'最多只能选择5个观众'
:
'You can only select up to 5 audience members'
,
{
confirmButtonText
:
language
.
value
==
0
?
'确定'
:
'Confirm'
,
cancelButtonText
:
language
.
value
==
0
?
'取消'
:
'Cancel'
,
type
:
'warning'
}
)
}
else
{
orderForm
.
value
.
num
=
orderForm
.
value
.
message
.
length
orderForm
.
value
.
customerList
=
orderForm
.
value
.
message
.
map
(
v
=>
v
.
id
)
customerArr_q
.
value
=
orderForm
.
value
.
message
.
filter
(
v
=>
!
v
.
discount
)
customerArr_b
.
value
=
orderForm
.
value
.
message
.
filter
(
v
=>
v
.
discount
)
// 计算价格
price
.
value
=
{
total_en
:
0
,
total_cn
:
0
,
total_enY
:
0
,
total_cnY
:
0
,
}
orderForm
.
value
.
message
.
forEach
(
v
=>
{
if
(
v
.
discount
)
{
price
.
value
.
total_cnY
=
price
.
value
.
total_cn
+=
(
tickType
.
value
.
rebatePrice
*
1
)
price
.
value
.
total_enY
=
price
.
value
.
total_en
+=
(
tickType
.
value
.
rebatePriceEn
*
1
)
getActivityTypeVoById
({
id
:
route
.
params
.
latstId
}).
then
((
res
)
=>
{
TickForm2
.
value
=
res
.
data
})
}
else
{
price
.
value
.
total_cnY
=
price
.
value
.
total_cn
+=
(
tickType
.
value
.
price
*
1
)
price
.
value
.
total_enY
=
price
.
value
.
total_en
+=
(
tickType
.
value
.
priceEn
*
1
)
}
}
)
getListByAtstId
({
atstId
:
route
.
params
.
latstId
}).
then
(
res
=>
{
TickForm3
.
value
=
res
.
data
})
})
// 计算购票优惠
if
(
tickType
.
value
.
isCountSale
==
1
&&
orderForm
.
value
.
message
.
length
>=
tickType
.
value
.
counts
)
{
price
.
value
.
total_cn
=
((
price
.
value
.
total_cn
*
(
tickType
.
value
.
discount
*
10
))
/
100
).
toFixed
(
2
)
price
.
value
.
total_en
=
((
price
.
value
.
total_en
*
(
tickType
.
value
.
discount
*
10
))
/
100
).
toFixed
(
2
)
}
}
console
.
log
(
orderForm
.
value
.
message
)
function
changeGroup
(
e
)
{
}
...
...
@@ -294,26 +224,6 @@ async function customerList() {
personnelList
.
value
=
res
.
rows
}
// 获取票档信息
async
function
getTicketListType
()
{
const
res
=
await
listApi
({
latId
:
orderForm
.
value
.
latId
}
)
tickType
.
value
=
res
.
rows
.
find
(
item
=>
item
.
id
==
orderForm
.
value
.
attId
)
orderForm
.
value
.
ticketDate
=
JSON
.
stringify
(
tickType
.
value
)
console
.
log
(
tickType
.
value
)
}
getTicketListType
()
// 票档信息
async
function
getTicketList
()
{
const
res
=
await
getTicketListApi
({
activityId
:
route
.
params
.
activeId
}
)
matchType
.
value
=
res
.
rows
.
find
(
item
=>
item
.
id
==
orderForm
.
value
.
atId
)
orderForm
.
value
.
ticketType
=
JSON
.
stringify
(
matchType
.
value
)
}
getTicketList
()
// 提交
async
function
paymentHandle
()
{
if
(
!
user
.
value
)
{
...
...
@@ -327,19 +237,37 @@ async function paymentHandle() {
confirmButtonText
:
language
.
value
==
0
?
'确定'
:
'Confirm'
,
cancelButtonText
:
language
.
value
==
0
?
'取消'
:
'Cancel'
,
type
:
'warning'
}
).
then
(
async
()
=>
{
}).
then
(
async
()
=>
{
try
{
const
orderCustomerList
=
[]
_
.
each
(
orderForm
.
value
.
customerIds
,
(
id
)
=>
{
const
person
=
_
.
find
(
personnelList
.
value
,
(
item
)
=>
item
.
id
==
id
)
orderCustomerList
.
push
({
customerId
:
person
.
id
,
name
:
person
.
name
,
idcType
:
person
.
idcType
,
idCard
:
person
.
idCard
,
paymentType
:
language
.
value
==
0
?
'1'
:
'3'
})
})
const
res
=
await
submitOrderTicket
({
activeId
:
orderForm
.
value
.
activeId
,
atId
:
orderForm
.
value
.
atId
,
attId
:
orderForm
.
value
.
attId
,
ticketType
:
orderForm
.
value
.
ticketType
,
ticketDate
:
orderForm
.
value
.
ticketDate
,
orderName
:
TickForm2
.
value
.
ticketTypeName
,
atId
:
TickForm2
.
value
.
latId
,
atType
:
TickForm2
.
value
.
ticketPackage
,
atName
:
TickForm2
.
value
.
ticketTypeName
,
atsId
:
TickForm2
.
value
.
latsId
,
atsName
:
TickForm2
.
value
.
stadiumName
,
sessionType
:
TickForm2
.
value
.
sessionType
,
atstId
:
TickForm2
.
value
.
id
,
atstName
:
TickForm2
.
value
.
ticketName
,
ticketName
:
TickForm2
.
value
.
ticketName
,
ticketType
:
TickForm2
.
value
.
ticketType
,
contacts
:
orderForm
.
value
.
contacts
,
phone
:
orderForm
.
value
.
phone
,
customerList
:
orderForm
.
value
.
customerList
,
num
:
orderForm
.
value
.
num
,
message
:
JSON
.
stringify
(
orderForm
.
value
.
message
),
total
:
language
.
value
==
0
?
price
.
value
.
total_cn
:
price
.
value
.
total_en
price
:
language
.
value
==
'0'
?
TickForm2
.
value
.
price
:
TickForm2
.
value
.
priceEn
,
orderCustomerList
:
orderCustomerList
})
if
(
res
.
code
==
200
&&
res
.
data
.
orderId
>
0
)
{
// 去付钱
...
...
@@ -371,26 +299,18 @@ async function paymentHandle() {
}
finally
{
}
})
}
async
function
getDetail
()
{
const
res
=
await
getTicketInfoByActivityId
({
activityId
:
orderForm
.
value
.
activeId
}
)
const
res
=
await
getTicketInfoByActivityId
({
activityId
:
orderForm
.
value
.
activeId
})
TickForm
.
value
=
res
.
data
}
getDetail
()
function
addPeopl
()
{
router
.
push
({
path
:
'/booking/ticket/peopleManage'
,
query
:
{
activeId
:
orderForm
.
value
.
activeId
,
attId
:
orderForm
.
value
.
attId
,
atId
:
orderForm
.
value
.
atId
}
path
:
'/booking/ticket/peopleManage'
})
}
</
script
>
...
...
src/viewsPc/booking/ticket/index.vue
View file @
8b639c6
...
...
@@ -37,11 +37,11 @@
<div
class=
"address"
>
{{
triggerLanguage
(
language
,
"地址"
,
"Location"
)
}}
:
{{
matchForm
.
address
}}
</div>
<div
v-if=
"timeData>0"
>
<!-- 倒计时-->
<p
class=
"countDownTitle"
>
<span
v-if=
"language==0"
>
售票倒计时
</span>
<span
v-else
>
TICKET COUNTDOWN
</span>
...
...
@@ -60,16 +60,40 @@
</van-count-down>
</div>
<div
v-else
>
<!-- 票档 -->
<div
class=
"select_item_box"
>
<div
class=
"label"
>
{{ triggerLanguage(language, "票档", "Tickets") }} :
</div>
<div
v-if=
"matchForm.ticketLayout"
>
</div>
<div
class=
"select_item_box"
>
<div
class=
"select_item"
>
<div
v-for=
"(it, index) in tickClass"
:key=
"index"
:class=
"[
it.id == selectForm.latId ? 'tagActive' : 'tag',
]"
@
click=
"select(it)"
>
{{ it.ticketTypeName }}
<span
v-if=
"it.ticketPackage==1"
class=
"tao"
>
{{
language == 0 ? '套票' : 'Package ticket'
}}
</span>
</div>
</div>
</div>
<!-- 场馆 -->
<div
class=
"select_item_box"
>
<div
class=
"label"
>
{{ triggerLanguage(language, "场馆", "Venues") }} :
</div>
<div>
<span
v-if=
"currVenue?.images"
style=
"color: #493ceb;cursor:pointer;font-weight:600;font-size: 14px"
@
click=
"show=true"
@
click=
"show
Url=currVenue.images; show
=true"
>
<span
style=
"color: red;font-size: 18px"
>
*
</span>
{{
language == 0 ? '点击查看场馆布局' : 'View Venue Layout'
...
...
@@ -80,19 +104,20 @@
<div
class=
"select_item_box"
>
<div
class=
"select_item"
>
<div
v-for=
"(it, index) in
tickClass
"
v-for=
"(it, index) in
venueList
"
:key=
"index"
:class=
"[
it.id == selectForm.latId ? 'tagActive' : 'tag',
it.id == selectForm.latsId ? 'tagActive' : 'tag',
it.isView==0?'forbid':''
]"
@
click=
"select(it)"
@
click=
"select
Venue
(it)"
>
{{ it.name }}
</div>
</div>
</div>
<!--
时间
-->
<!--
场次
-->
<div
class=
"select_item_box"
>
<div
class=
"label"
>
{{ triggerLanguage(language, "场次", "Session") }} :
...
...
@@ -101,21 +126,53 @@
<div
class=
"select_item_box"
>
<div
class=
"select_item"
>
<div
v-for=
"(it,
index
) in tickList"
:key=
"
index
"
v-for=
"(it,
key
) in tickList"
:key=
"
key
"
:class=
"[
it.id == selectForm.id ? 'tagActive' : 'tag',
key == selectForm.sessionType ? 'tagActive' : 'tag',
it.isView==0?'forbid':''
]"
@
click=
"selectSessionType(key)"
>
{{ key=='1000'?'日间场':'夜间场' }}
</div>
</div>
</div>
<!-- 票型 -->
<div
class=
"select_item_box"
>
<div
class=
"label"
>
{{ triggerLanguage(language, "票型", "Ticket Type") }} :
</div>
<div>
<span
v-if=
"currTick?.images"
style=
"color: #493ceb;cursor:pointer;font-weight:600;font-size: 14px"
@
click=
"showUrl=currTick.images;show=true"
>
<span
style=
"color: red;font-size: 18px"
>
*
</span>
{{
language == 0 ? '点击查看区域布局' : 'View Area Layout'
}}
</span>
</div>
</div>
<div
class=
"select_item_box"
>
<div
class=
"select_item"
>
<div
v-for=
"it in tickList[selectForm.sessionType]"
:key=
"it.id"
:class=
"[
it.id == selectForm.latstId ? 'tagActive' : 'tag',
it.isView==0?'forbid':''
]"
@
click=
"selectTick(it)"
>
{{ it.name }}
<span
v-if=
"it.ticketType==1"
class=
"tao"
>
{{
language == 0 ? '套票' : 'Package ticket'
}}
</span>
{{ it.name }}
</div>
</div>
</div>
<!-- 价格 -->
<div
class=
"select_item_box"
>
<div
class=
"label"
>
...
...
@@ -142,7 +199,7 @@
{{ matchForm.ticketRemark }}
</div>
</div>
<div
v-if=
"endTime<=0"
class=
"btn"
style=
"margin-left: 40px;opacity: 0.5;cursor: not-allowed;margin-top: 10px"
@
click=
"toSelectClosed"
...
...
@@ -156,12 +213,12 @@
triggerLanguage(language, "立即购票", "Buy tickets now")
}}
</div>
</div>
</div>
</div>
<div
class=
"container bottom"
>
<div
style=
"display: flex"
>
<div
:class=
"{'bg':active==1}"
class=
"buBg"
@
click=
"active=1"
>
购票说明
</div>
...
...
@@ -169,10 +226,10 @@
</div>
<div
v-show=
"active==1"
class=
"rich_content"
v-html=
"matchForm.ticketDes"
/>
<div
v-show=
"active==2"
class=
"rich_content"
v-html=
"matchForm.ticketNotice"
/>
<el-dialog
v-model=
"show"
title=
""
width=
"1000px"
>
<div>
<img
:src=
"fillImgUrl(
matchForm.ticketLayout
)"
alt=
""
style=
"width: 100%"
>
<img
:src=
"fillImgUrl(
showUrl
)"
alt=
""
style=
"width: 100%"
>
</div>
</el-dialog>
</div>
...
...
@@ -181,16 +238,23 @@
<
script
setup
>
import
{
ref
,
computed
}
from
'vue'
import
{
listApi
,
getTicketInfoByActivityId
,
getTicketListApi
,
checkNonPayment
}
from
'@/apiPc/booking'
import
{
ref
,
computed
,
watch
}
from
'vue'
import
{
getTicketInfoByActivityId
,
getTicketListApi
,
checkNonPayment
,
getStadiumList
,
getActivityTypeVoListByLatsId
}
from
'@/apiPc/booking'
import
{
dayjs
}
from
'element-plus'
import
{
ElMessageBox
,
ElMessage
}
from
'element-plus'
import
{
languageFormat
,
getDayName
}
from
'@/viewsPc/seat/utils/language'
import
{
getDayName
}
from
'@/viewsPc/seat/utils/language'
import
{
fillImgUrl
}
from
'/@/utils/ruoyi'
import
useUserStore
from
'/@/store/modules/user'
import
{
triggerLanguage
}
from
'@/utils/ruoyi'
import
{
useStorage
}
from
'@vueuse/core/index'
import
{
useRoute
,
useRouter
}
from
'vue-router'
const
language
=
useStorage
(
'language'
,
0
)
const
useStore
=
useUserStore
()
...
...
@@ -198,10 +262,9 @@ const user = computed(() => useUserStore().user)
const
route
=
useRoute
()
const
router
=
useRouter
()
const
show
=
ref
(
false
)
const
showUrl
=
ref
(
''
)
const
activeId
=
ref
(
route
.
params
.
activeId
)
const
flag
=
ref
(
false
)
const
active
=
ref
(
1
)
const
countDown
=
ref
(
false
)
const
props
=
defineProps
({
activityId
:
[
String
,
Number
]
})
...
...
@@ -211,11 +274,22 @@ const matchForm = ref({})
const
tickClass
=
ref
([])
const
selectForm
=
ref
({
latId
:
null
,
id
:
null
,
latsId
:
null
,
sessionType
:
null
,
latstId
:
null
,
price
:
'--'
,
priceEn
:
'--'
})
const
venueList
=
ref
([])
const
tickList
=
ref
([])
const
currVenue
=
ref
(
null
)
const
currTick
=
ref
(
null
)
watch
(
show
,
(
val
)
=>
{
if
(
!
val
)
{
showUrl
.
value
=
''
}
})
// 获取票务信息
getDetail
()
...
...
@@ -241,48 +315,74 @@ async function getTicketList() {
tickClass
.
value
=
res
.
rows
if
(
tickClass
.
value
.
length
>
0
)
{
selectForm
.
value
.
latId
=
tickClass
.
value
?.[
0
]?.
id
await
get
TicketListType
()
await
get
VenueList
()
}
}
// 根据票档获取场次
async
function
getVenueList
()
{
const
res
=
await
getStadiumList
({
latId
:
selectForm
.
value
.
latId
})
venueList
.
value
=
res
.
rows
currVenue
.
value
=
res
.
rows
[
0
]
selectForm
.
value
.
latsId
=
res
.
rows
[
0
]?.
id
await
getTicketListType
()
}
// 根据票档获取场次
async
function
getTicketListType
()
{
const
arr
=
[]
const
res
=
await
listApi
({
latId
:
selectForm
.
value
.
latId
})
tickList
.
value
=
res
.
rows
for
(
const
v
of
res
.
rows
)
{
if
(
v
.
isView
==
0
)
arr
.
push
(
v
)
}
for
(
const
v
of
res
.
rows
)
{
if
(
arr
.
length
>
0
&&
v
.
ticketType
==
1
)
{
for
(
const
c
of
arr
)
{
if
((
c
.
ticketStart
>=
v
.
ticketStart
)
&&
(
c
.
ticketStart
<=
v
.
ticketEnd
))
{
v
.
isView
=
0
}
}
}
}
const
res
=
await
getActivityTypeVoListByLatsId
({
latsId
:
selectForm
.
value
.
latsId
})
tickList
.
value
=
res
.
data
selectForm
.
value
.
sessionType
=
Object
.
keys
(
res
.
data
)[
0
]
currTick
.
value
=
tickList
.
value
[
selectForm
.
value
.
sessionType
][
0
]
selectForm
.
value
.
latstId
=
currTick
.
value
?.
id
selectForm
.
value
.
price
=
currTick
.
value
?.
price
selectForm
.
value
.
priceEn
=
currTick
.
value
?.
priceEn
}
function
select
(
v
)
{
selectForm
.
value
.
latId
=
v
.
id
selectForm
.
value
.
latsId
=
null
selectForm
.
value
.
sessionType
=
null
selectForm
.
value
.
latstId
=
null
selectForm
.
value
.
id
=
null
selectForm
.
value
.
price
=
'--'
selectForm
.
value
.
priceEn
=
'--'
getVenueList
()
}
function
selectVenue
(
v
)
{
currVenue
.
value
=
v
selectForm
.
value
.
latsId
=
v
.
id
selectForm
.
value
.
sessionType
=
null
selectForm
.
value
.
latstId
=
null
selectForm
.
value
.
id
=
null
selectForm
.
value
.
price
=
'--'
selectForm
.
value
.
priceEn
=
'--'
getTicketListType
()
}
function
selectSessionType
(
key
)
{
selectForm
.
value
.
sessionType
=
key
currTick
.
value
=
tickList
.
value
[
selectForm
.
value
.
sessionType
][
0
]
selectForm
.
value
.
latstId
=
currTick
.
value
?.
id
selectForm
.
value
.
price
=
currTick
.
value
?.
price
selectForm
.
value
.
priceEn
=
currTick
.
value
?.
priceEn
}
function
selectTick
(
v
)
{
if
(
v
.
isView
!=
0
)
{
selectForm
.
value
.
id
=
v
.
id
selectForm
.
value
.
price
=
v
.
price
selectForm
.
value
.
priceEn
=
v
.
priceEn
}
currTick
.
value
=
v
selectForm
.
value
.
latstId
=
v
.
id
selectForm
.
value
.
price
=
v
.
price
selectForm
.
value
.
priceEn
=
v
.
priceEn
}
function
toSelectSeat
()
{
if
(
!
selectForm
.
value
.
latId
)
return
ElMessage
.
error
(
language
.
value
==
0
?
'请选择票档'
:
'Please select a ticket file'
)
if
(
!
selectForm
.
value
.
id
)
return
ElMessage
.
error
(
language
.
value
==
0
?
'请选择时间'
:
'Please select time'
)
//
if (!selectForm.value.latId) return ElMessage.error(language.value == 0 ? '请选择票档' : 'Please select a ticket file')
//
if (!selectForm.value.id) return ElMessage.error(language.value == 0 ? '请选择时间' : 'Please select time')
if
(
!
user
.
value
)
{
useStore
.
setVisitor
()
return
...
...
@@ -293,8 +393,7 @@ function toSelectSeat() {
name
:
'confirmOrder'
,
params
:
{
activeId
:
activeId
.
value
,
latId
:
selectForm
.
value
.
latId
,
attId
:
selectForm
.
value
.
id
latstId
:
selectForm
.
value
.
latstId
}
})
}
else
{
...
...
@@ -345,18 +444,18 @@ function toSelectClosed() {
display
:
flex
;
padding
:
19px
;
margin-top
:
26px
;
.cover_img
{
width
:
390px
;
height
:
517px
;
object-fit
:
fill
;
margin-right
:
36px
;
}
.info
{
padding-top
:
12px
;
width
:
100%
;
.title
{
font-weight
:
bold
;
font-size
:
28px
;
...
...
@@ -364,7 +463,7 @@ function toSelectClosed() {
line-height
:
1.6
;
margin-bottom
:
15px
;
}
.time
{
font-weight
:
600
;
font-size
:
16px
;
...
...
@@ -372,7 +471,7 @@ function toSelectClosed() {
line-height
:
24px
;
margin-bottom
:
16px
;
}
.address
{
font-weight
:
600
;
font-size
:
16px
;
...
...
@@ -380,15 +479,15 @@ function toSelectClosed() {
line-height
:
24px
;
margin-bottom
:
15px
;
}
.select_item_box
{
display
:
flex
;
margin-bottom
:
10px
;
&:last-child
{
margin-bottom
:
0
;
}
.label
{
font-weight
:
600
;
font-size
:
16px
;
...
...
@@ -397,18 +496,18 @@ function toSelectClosed() {
margin-right
:
12px
;
flex-shrink
:
0
;
}
.forbid
{
opacity
:
0.5
!important
;
cursor
:
not-allowed
!important
;
}
.select_item
{
display
:
flex
;
flex-wrap
:
wrap
;
gap
:
10px
;
user-select
:
none
;
.tag_t
{
padding
:
1px
15px
;
font-weight
:
400
;
...
...
@@ -418,7 +517,7 @@ function toSelectClosed() {
border
:
1px
solid
#453dea
;
margin-left
:
5px
;
}
.tag
{
display
:
flex
;
padding
:
12px
18px
;
...
...
@@ -429,7 +528,7 @@ function toSelectClosed() {
color
:
#4a4a4a
;
cursor
:
pointer
;
}
.tagActive
{
display
:
flex
;
padding
:
12px
18px
;
...
...
@@ -440,14 +539,14 @@ function toSelectClosed() {
color
:
#493ceb
;
cursor
:
pointer
;
}
.tao
{
border
:
1px
solid
#493ceb
;
font-size
:
14px
;
color
:
#493ceb
;
margin-left
:
10px
;
}
.tagDisabled
{
padding
:
12px
18px
;
background
:
#878787
;
...
...
@@ -459,7 +558,7 @@ function toSelectClosed() {
}
}
}
.btn
{
width
:
175px
;
height
:
40px
;
...
...
@@ -479,7 +578,7 @@ function toSelectClosed() {
padding
:
50px
;
margin-top
:
30px
;
margin-bottom
:
30px
;
.title
{
padding
:
20px
30px
;
background
:
linear-gradient
(
270deg
,
#493ceb
0%
,
#8623fc
100%
);
...
...
@@ -489,15 +588,15 @@ function toSelectClosed() {
line-height
:
30px
;
margin-bottom
:
30px
;
}
.rich_content
{
margin-top
:
30px
;
:deep(img)
{
width
:
100%
!important
;
height
:
auto
!important
;
}
}
}
...
...
@@ -515,44 +614,44 @@ function toSelectClosed() {
height
:
160px
;
margin-right
:
15px
;
}
.info
{
padding
:
0
;
.title
{
font-size
:
14px
;
margin
:
0
;
}
.time
,
.address
,
.label
,
.tip
{
font-size
:
12px
;
}
.title
,
.time
,
.address
,
.tip
,
.select_item_box
{
margin-bottom
:
3px
;
}
.select_item_box
{
.label
{
font-size
:
12px
;
}
.select_item
.tag
{
padding
:
2px
10px
;
font-size
:
12px
;
}
.select_item
.tagActive
{
padding
:
2px
10px
;
font-size
:
12px
;
}
.select_item
.tagDisabled
{
padding
:
2px
10px
;
font-size
:
12px
;
}
}
.btn
{
display
:
inline-block
;
margin
:
10px
0
0
;
...
...
@@ -570,8 +669,8 @@ function toSelectClosed() {
.bottom
{
padding
:
0
}
}
.countDownTitle
{
...
...
src/viewsPc/booking/ticket/peopleManage.vue
View file @
8b639c6
...
...
@@ -5,17 +5,16 @@
{{
languageFormat
(
language
,
"新增"
,
"Add"
)
}}
</div>
<span>
{{
languageFormat
(
language
,
"观影人管理"
,
"Viewers"
)
}}
{{
languageFormat
(
language
,
"观影人管理"
,
"Viewers"
)
}}
</span>
<span
class=
"fr"
style=
"cursor: pointer"
@
click=
"$router.go(-1)"
>
{{
language
==
0
?
'返回'
:
'Back'
}}
</span>
<span
class=
"fr"
style=
"cursor: pointer"
@
click=
"$router.go(-1)"
>
{{
language
==
0
?
'返回'
:
'Back'
}}
</span>
</div>
<div
class=
"content"
>
<div
class=
"people_box"
>
<div
v-for=
"(it, index) in personnelList"
:key=
"index"
class=
"people_item"
>
<div
v-for=
"(it, index) in personnelList"
:key=
"index"
class=
"people_item"
>
<div
class=
"name"
>
{{
it
.
name
}}
</div>
<div
class=
"idcard"
>
{{
languageFormat
(
language
,
"证件号"
,
"ID number"
)
}}
:
{{
it
.
idCard
}}
...
...
@@ -33,33 +32,31 @@
center
width=
"700"
>
<el-form
ref=
"formRef"
:model=
"form"
:rules=
"rules"
label-width=
"100px"
size=
"large"
style=
"margin: 80px"
>
<el-form
ref=
"formRef"
:model=
"form"
:rules=
"rules"
label-width=
"100px"
size=
"large"
style=
"margin: 80px"
>
<el-form-item
:label=
"language==0?'姓名':'name'"
prop=
"name"
required
>
<el-input
v-model=
"form.name"
:placeholder=
"language==0?'请输入':'Please input'"
/>
<el-input
v-model=
"form.name"
:placeholder=
"language==0?'请输入':'Please input'"
/>
</el-form-item>
<el-form-item
:label=
"language==0?'证件类型':'ID Type'"
prop=
"idcType"
required
>
<el-select
v-model=
"form.idcType"
:placeholder=
"language==0?'请选择':'Please choose'"
>
<el-option
:label=
"language==0?'身份证':'Identity card'"
value=
"0"
/>
<el-option
:label=
"language==0?'护照':'Passport'"
value=
"1"
/>
<el-option
:label=
"language==0?'其他':'Other'"
value=
"2"
/>
<el-option
:label=
"language==0?'身份证':'Identity card'"
value=
"0"
/>
<el-option
:label=
"language==0?'护照':'Passport'"
value=
"1"
/>
<el-option
:label=
"language==0?'其他':'Other'"
value=
"2"
/>
</el-select>
</el-form-item>
<el-form-item
:label=
"language==0?'证件号':'ID number'"
prop=
"idCard"
required
>
<el-input
v-model=
"form.idCard"
:placeholder=
"language==0?'请输入证件号':'Please enter the ID after ah'"
/>
<el-input
v-model=
"form.idCard"
:placeholder=
"language==0?'请输入证件号':'Please enter the ID after ah'"
/>
</el-form-item>
</el-form>
<br>
<br>
<span
slot=
"footer"
class=
"dialog-footer"
>
<span
class=
"dialog-footer"
>
<div
style=
"text-align: center"
>
<el-button
class=
"can_pay"
@
click=
"show = false"
>
{{
language
==
0
?
'取 消'
:
'cancel'
}}
</el-button>
<el-button
class=
"pay"
type=
"primary"
@
click=
"submit"
>
{{
language
==
0
?
'确 定'
:
'confirm'
}}
</el-button>
</div>
</span>
<br>
<br>
<br>
</el-dialog>
</el-card>
...
...
@@ -67,13 +64,14 @@
<
script
setup
>
import
{
ref
,
computed
}
from
"vue"
;
import
{
aadCustomer
,
customerListApi
,
delCustomer
}
from
'@/apiPc/booking'
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
{
languageFormat
}
from
"@/viewsPc/seat/utils/language.js"
;
import
useUserStore
from
"/@/store/modules/user"
;
import
{
useStorage
}
from
"@vueuse/core/index"
;
import
{
triggerLanguage
}
from
'@/utils/ruoyi'
import
{
ref
,
computed
}
from
'vue'
import
{
aadCustomer
,
delCustomer
,
getMyFriends
}
from
'@/apiPc/booking'
import
{
ElMessage
,
ElMessageBox
}
from
'element-plus'
import
{
languageFormat
}
from
'@/viewsPc/seat/utils/language.js'
import
useUserStore
from
'/@/store/modules/user'
import
{
useStorage
}
from
'@vueuse/core/index'
import
{
triggerLanguage
}
from
'@/utils/ruoyi'
import
{
useRoute
}
from
'vue-router'
const
user
=
computed
(()
=>
useUserStore
().
user
)
const
useStore
=
useUserStore
()
...
...
@@ -85,29 +83,25 @@ const form = ref({})
const
formRef
=
ref
(
null
)
const
rules
=
ref
({
name
:
[
{
required
:
true
,
message
:
triggerLanguage
(
language
.
value
,
'请输入姓名'
,
'Please input'
),
trigger
:
"blur"
},
{
required
:
true
,
message
:
triggerLanguage
(
language
.
value
,
'请输入姓名'
,
'Please input'
),
trigger
:
'blur'
}
],
idCard
:
[
{
required
:
true
,
message
:
triggerLanguage
(
language
.
value
,
'请输入证件号'
,
'Please enter the ID after ah'
),
trigger
:
"blur"
}
,
trigger
:
'blur'
}
],
idcType
:
[
{
required
:
true
,
message
:
triggerLanguage
(
language
.
value
,
'请选择证件类型'
,
'Please choose'
),
trigger
:
"blur"
},
]
,
{
required
:
true
,
message
:
triggerLanguage
(
language
.
value
,
'请选择证件类型'
,
'Please choose'
),
trigger
:
'blur'
}
]
})
customerList
()
async
function
customerList
()
{
const
res
=
await
customerListApi
({
activeId
:
route
.
query
.
activeId
,
attId
:
route
.
query
.
attId
,
atId
:
route
.
query
.
atId
})
personnelList
.
value
=
res
.
rows
const
res
=
await
getMyFriends
()
personnelList
.
value
=
res
.
data
}
function
addPeople
()
{
...
...
@@ -125,19 +119,18 @@ function submit() {
if
(
valid
)
{
aadCustomer
(
form
.
value
).
then
(
res
=>
{
if
(
res
.
data
==
-
100
)
{
ElMessageBox
.
confirm
(
language
.
value
==
0
?
'该观影人已存在'
:
"The viewer already exists"
,
language
.
value
==
0
?
'提示'
:
'Reminder'
,
{
ElMessageBox
.
confirm
(
language
.
value
==
0
?
'该观影人已存在'
:
'The viewer already exists'
,
language
.
value
==
0
?
'提示'
:
'Reminder'
,
{
confirmButtonText
:
language
.
value
==
0
?
'确认'
:
'confirm'
,
cancelButtonText
:
language
.
value
==
0
?
'取消'
:
'cancel'
,
type
:
"warning"
,
draggable
:
true
,
type
:
'warning'
,
draggable
:
true
})
}
else
if
(
res
.
data
==
-
101
)
{
return
ElMessageBox
.
confirm
(
language
.
value
==
0
?
'该观影人实名认证未通过'
:
'The real name authentication of the moviegoer failed'
,
language
.
value
==
0
?
'提示'
:
'Reminder'
,
{
confirmButtonText
:
language
.
value
==
0
?
'确认'
:
"confirm"
,
confirmButtonText
:
language
.
value
==
0
?
'确认'
:
'confirm'
,
cancelButtonText
:
language
.
value
==
0
?
'取消'
:
'cancel'
,
type
:
"warning"
,
draggable
:
true
,
type
:
'warning'
,
draggable
:
true
})
}
else
{
show
.
value
=
false
...
...
@@ -153,23 +146,22 @@ function submit() {
async
function
deletePeople
(
v
)
{
await
ElMessageBox
.
confirm
(
languageFormat
(
language
.
value
,
"确认删除该观影人吗?"
,
"Are you sure to delete this viewer?"
),
languageFormat
(
language
.
value
,
"提示"
,
"Reminder"
),
{
confirmButtonText
:
languageFormat
(
language
.
value
,
"确认"
,
"confirm"
),
cancelButtonText
:
languageFormat
(
language
.
value
,
"取消"
,
"cancel"
),
type
:
"warning"
,
draggable
:
true
,
}
)
.
then
(
async
()
=>
{
languageFormat
(
language
.
value
,
'确认删除该观影人吗?'
,
'Are you sure to delete this viewer?'
),
languageFormat
(
language
.
value
,
'提示'
,
'Reminder'
),
{
confirmButtonText
:
languageFormat
(
language
.
value
,
'确认'
,
'confirm'
),
cancelButtonText
:
languageFormat
(
language
.
value
,
'取消'
,
'cancel'
),
type
:
'warning'
,
draggable
:
true
}
)
.
then
(
async
()
=>
{
const
res
=
await
delCustomer
(
v
)
if
(
res
.
code
===
200
)
{
ElMessage
.
success
(
'删除成功'
)
await
customerList
()
}
})
}
</
script
>
...
...
vite.config.js
View file @
8b639c6
...
...
@@ -81,8 +81,8 @@ export default defineConfig(({ mode, command }) => {
rewrite
:
(
p
)
=>
p
.
replace
(
/^
\/
dev-api
\/
ztx-webSite/
,
''
)
},
'/dev-api'
:
{
//
target: 'http://192.168.1.118:8081/',
target
:
'http://192.168.1.243:8081'
,
target
:
'http://192.168.1.118:8081/'
,
//
target: 'http://192.168.1.243:8081',
// target: 'https://jijin.wtwuxicenter.com/stage-api',
// target: 'https://wdsfwuxicenter.com/stage-api/',
changeOrigin
:
true
,
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment