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
d7b0a1d3
authored
2024-04-19 09:29:22 +0800
by
杨炀
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
no message
1 parent
83f70075
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
62 additions
and
21 deletions
src/apiPc/common.js
src/routerPc/en.js
src/viewsPc/booking/hotelOrder.vue
src/viewsPc/booking/pay.vue
src/viewsPc/center/myReservation.vue
src/viewsPc/components/homeQuick.vue
src/apiPc/common.js
View file @
d7b0a1d
...
...
@@ -40,3 +40,10 @@ export function getIndexScheduleList(params) {
params
:
params
})
}
export
function
newbilllist
(
query
)
{
return
request
({
url
:
`/ota/norder/list`
,
method
:
'get'
,
params
:
query
})
}
...
...
src/routerPc/en.js
View file @
d7b0a1d
...
...
@@ -391,6 +391,12 @@ export const constantRoutes = [
name
:
'photography'
,
meta
:
{
title
:
'Photography Appointment'
}
},
{
path
:
'pay'
,
component
:
()
=>
import
(
'@/viewsPc/booking/pay'
),
name
:
'bookingPay'
,
meta
:
{
title
:
'pay'
}
}
]
},
{
...
...
src/viewsPc/booking/hotelOrder.vue
View file @
d7b0a1d
...
...
@@ -44,7 +44,7 @@
</div>
</el-form-item>
<el-form-item
v-for=
"(n,index) in form.roomNum"
:key=
"index"
:label=
"`入住人$
{index+1}`">
<el-input
v-model=
"rzUserArr[index]"
placeholder=
"每间填一位住客姓名
"
/>
<el-input
v-model=
"rzUserArr[index]"
:placeholder=
"language==0?'每间填一位住客姓名':'Each room fill in one name of the guest'
"
/>
</el-form-item>
<el-form-item
:label=
"language==0?'预计到店':'Expected check-in'"
>
<el-select
v-model=
"form.ddDate"
...
...
@@ -143,8 +143,9 @@ import {ref, reactive, onMounted} from "vue";
import
{
useStorage
}
from
"@vueuse/core/index"
;
import
{
checkResidueRoom
,
newsSubmitOrderHotel
}
from
"@/apiPc/booking"
import
dayjs
from
'dayjs'
import
{
ElMessage
}
from
"element-plus"
;
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
;
import
useUserStore
from
"@/store/modules/user"
;
const
user
=
useUserStore
().
user
const
language
=
useStorage
(
'language'
,
0
)
const
router
=
useRouter
()
const
route
=
useRoute
()
...
...
@@ -324,6 +325,10 @@ function countMoney() {
}
function
submit
()
{
if
(
!
user
){
useUserStore
().
setReLogin
()
}
if
(
usedays
==
0
)
{
ElMessage
.
error
(
language
.
value
==
0
?
'入住时间跨度需大于一天'
:
'Check-in time must be greater than one day'
)
return
...
...
@@ -365,7 +370,7 @@ function submit() {
console
.
log
(
form
.
value
.
room
)
// 提交确认
ElMessage
.
confirm
(
language
.
value
==
0
?
'确认提交订单吗?'
:
'Confirm to submit the order?'
,
{
ElMessage
Box
.
confirm
(
language
.
value
==
0
?
'确认提交订单吗?'
:
'Confirm to submit the order?'
,
{
confirmButtonText
:
language
.
value
==
0
?
'确定'
:
'Confirm'
,
cancelButtonText
:
language
.
value
==
0
?
'取消'
:
'Cancel'
,
type
:
'warning'
...
...
@@ -377,6 +382,13 @@ function submit() {
checkreRooms
()
}
else
{
//去付钱
router
.
push
({
name
:
'bookingPay'
,
query
:
{
orderId
:
res
.
data
.
orderId
,
money
:
res
.
data
.
total
}
})
}
}
else
{
ElMessage
.
warning
(
language
.
value
==
0
?
'无可预定的房间'
:
'No rooms available to book'
)
...
...
@@ -385,21 +397,6 @@ function submit() {
})
}
function
pay
()
{
//确认付款
ElMessage
.
confirm
(
language
.
value
==
0
?
'确认付款吗?'
:
'Confirm payment?'
,
{
confirmButtonText
:
language
.
value
==
0
?
'确定'
:
'Confirm'
,
cancelButtonText
:
language
.
value
==
0
?
'取消'
:
'Cancel'
,
type
:
'warning'
}).
then
(()
=>
{
newsSubmitOrderHotel
(
form
.
value
).
then
(
res
=>
{
if
(
res
.
data
)
{
if
(
res
.
data
.
roomNum
==
-
100
)
{
}
}
})
})
}
</
script
>
<
style
scoped
lang=
"scss"
>
...
...
src/viewsPc/booking/pay.vue
0 → 100644
View file @
d7b0a1d
This diff is collapsed.
Click to expand it.
src/viewsPc/center/myReservation.vue
View file @
d7b0a1d
...
...
@@ -3,7 +3,25 @@
<el-card
:body-style=
"
{'padding':'0'}">
<div
class=
"indexTitle"
><h3
class=
"leftboderTT"
>
{{
language
==
0
?
'我的预订'
:
'My reservation'
}}
</h3></div>
<el-empty
:image=
"`/img/order_no.png`"
:image-size=
"228"
v-if=
"list?.length == 0"
/>
<div
v-for=
"b in list"
>
<h3>
{{
b
.
name
}}
</h3>
<div
v-if=
"b.orderType == 0"
>
<div><label
class=
"blueTag"
>
酒店订单
</label>
订单编号:
{{
b
.
id
}}
</div>
<div>
{{
b
.
messageObj
?.
roomStayDate
}}
</div>
<div>
{{
b
.
messageObj
?.
roomName
}}
</div>
<div>
{{
b
.
messageObj
?.
roomInfo
}}
</div>
</div>
{{
b
}}
</div>
<div
class=
"pd20"
></div>
</el-card>
</div>
...
...
@@ -12,8 +30,21 @@
<
script
setup
>
import
{
onMounted
}
from
"@vue/runtime-core"
;
import
{
useStorage
}
from
"@vueuse/core/index"
;
import
{
newbilllist
}
from
"@/apiPc/common"
;
const
language
=
useStorage
(
'language'
,
0
)
const
list
=
ref
([])
onMounted
(()
=>
{
getList
()
})
function
getList
()
{
newbilllist
().
then
(
res
=>
{
list
.
value
=
res
.
rows
for
(
var
b
of
list
.
value
)
{
b
.
messageObj
=
JSON
.
parse
(
b
.
message
)
}
})
}
</
script
>
<
style
scoped
lang=
"scss"
>
...
...
src/viewsPc/components/homeQuick.vue
View file @
d7b0a1d
...
...
@@ -68,8 +68,8 @@ const props = defineProps({
})
const
language
=
useStorage
(
'language'
,
0
)
function
goBooking
(
n
)
{
ElMessage
.
warning
(
language
.
value
==
0
?
'建设中,敬请期待'
:
'Building!'
)
return
//
ElMessage.warning(language.value==0?'建设中,敬请期待':'Building!')
//
return
switch
(
n
)
{
case
0
:
// 票务
...
...
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