Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
A
ABC_Hotel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Đinh Quang Vinh
ABC_Hotel
Commits
cd02b769
Commit
cd02b769
authored
Aug 04, 2023
by
vinh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
commit
parent
56c9fcbb
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
42 additions
and
17 deletions
+42
-17
NavbarHotel.vue
src/components/NavbarHotel.vue
+16
-2
CheckinView.vue
src/views/CheckinView.vue
+21
-10
DashboardView.vue
src/views/DashboardView.vue
+3
-3
RoomView.vue
src/views/RoomView.vue
+2
-2
No files found.
src/components/NavbarHotel.vue
View file @
cd02b769
...
...
@@ -45,7 +45,7 @@
</router-link>
</div>
<div
class=
"logout"
@
click=
"logout"
>
<i
class=
"bi bi-box-arrow-right icon"
>
Logout
</i>
<i
class=
"bi bi-box-arrow-right icon"
>
</i>
Logout
</div>
</div>
</
template
>
...
...
@@ -91,7 +91,7 @@ export default {
}
.icon
{
color
:
rgb
(
150
,
150
,
150
);
color
:
rgb
(
74
,
74
,
74
);
font-size
:
25px
;
}
...
...
@@ -152,4 +152,18 @@ export default {
background-color
:
rgb
(
247
,
108
,
105
);
color
:
#fff
;
}
@media
(
max-width
:
425px
)
{
.logout
{
cursor
:
pointer
;
padding-left
:
20px
;
font-size
:
15px
;
display
:
flex
;
gap
:
15px
;
padding
:
15px
;
min-height
:
100px
;
align-items
:
center
;
background-color
:
rgb
(
247
,
108
,
105
);
}
}
</
style
>
src/views/CheckinView.vue
View file @
cd02b769
...
...
@@ -108,20 +108,19 @@ export default defineComponent({
const
viewDetail
=
async
(
checkinId
,
bookingId
)
=>
{
try
{
console
.
log
(
checkinId
,
bookingId
)
const
response
=
await
axios
.
post
(
'
checkin/checkin-detail
'
,
{
checkinId
:
checkinId
,
bookingId
:
bookingId
})
CheckinDetail
.
value
=
{
'
Guest name
'
:
response
.
data
.
guest_name
,
'
Guest number
'
:
response
.
data
.
guest_number
,
'
Booked time
'
:
response
.
data
.
created_at
,
'
Employee id
'
:
response
.
data
.
id
,
'
Employee name
'
:
response
.
data
.
name
,
'
Employee role
'
:
response
.
data
.
role
,
'
Guest name
'
:
response
.
data
[
0
]
.
guest_name
,
'
Guest number
'
:
response
.
data
[
0
]
.
guest_number
,
'
Booked time
'
:
response
.
data
[
0
]
.
created_at
,
'
Employee id
'
:
response
.
data
[
1
]
.
id
,
'
Employee name
'
:
response
.
data
[
1
]
.
name
,
'
Employee role
'
:
response
.
data
[
1
]
.
role
,
}
console
.
log
(
CheckinDetail
.
value
)
console
.
log
(
response
.
data
[
1
]
)
document
.
getElementById
(
'
detail-modal
'
).
style
.
display
=
'
block
'
}
catch
(
error
)
{
console
.
error
(
error
.
response
.
data
)
...
...
@@ -155,9 +154,21 @@ export default defineComponent({
}
const
exportData
=
async
()
=>
{
try
{
const
response
=
await
axios
.
get
(
'
checkin/export
'
)
console
.
log
(
response
.
data
)
axios
({
method
:
'
GET
'
,
url
:
'
checkin/export
'
,
responseType
:
'
blob
'
,
}).
then
(
response
=>
{
const
url
=
window
.
URL
.
createObjectURL
(
new
Blob
([
response
.
data
]));
const
link
=
document
.
createElement
(
'
a
'
);
link
.
href
=
url
;
link
.
setAttribute
(
'
download
'
,
'
data.csv
'
);
// Specify the filename
document
.
body
.
appendChild
(
link
);
link
.
click
();
document
.
body
.
removeChild
(
link
);
});
}
catch
(
error
)
{
console
.
error
(
error
.
response
.
data
)
}
...
...
src/views/DashboardView.vue
View file @
cd02b769
...
...
@@ -188,11 +188,11 @@ export default defineComponent({
async
mounted
()
{
this
.
loaded
=
false
try
{
const
bookingThisYear
=
await
axios
.
get
(
'
booking-this-year
'
)
const
bookingThisYear
=
await
axios
.
get
(
'
dashboard/
booking-this-year
'
)
this
.
LineChartData
.
datasets
[
0
].
data
=
bookingThisYear
.
data
const
interestThisYear
=
await
axios
.
get
(
'
interest-this-year
'
)
const
interestThisYear
=
await
axios
.
get
(
'
dashboard/
interest-this-year
'
)
this
.
BarChartData
.
datasets
[
0
].
data
=
interestThisYear
.
data
const
IncomeAndSalary
=
await
axios
.
get
(
'
income-this-month
'
)
const
IncomeAndSalary
=
await
axios
.
get
(
'
dashboard/
income-this-month
'
)
this
.
PieChartData
.
datasets
[
0
].
data
=
IncomeAndSalary
.
data
this
.
loaded
=
true
}
catch
(
e
)
{
...
...
src/views/RoomView.vue
View file @
cd02b769
...
...
@@ -63,7 +63,7 @@ export default {
const
modifyRoom
=
(
id
)
=>
{
//router push to modify room
router
.
push
(
'
/modify/
'
+
id
)
router
.
push
(
'
room
/modify/
'
+
id
)
}
const
handleFileUpload
=
(
event
)
=>
{
...
...
@@ -71,7 +71,7 @@ export default {
}
const
viewRoomDetail
=
async
(
id
)
=>
{
let
response
=
await
axios
.
post
(
'
room-detail
'
,
{
let
response
=
await
axios
.
post
(
'
room
/room
-detail
'
,
{
id
:
id
})
roomInfo
.
value
=
{
...
...
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