Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
B
bigwood
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
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
罗超
bigwood
Commits
d462445d
Commit
d462445d
authored
Nov 25, 2022
by
youjie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
4a81f725
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
30 additions
and
8 deletions
+30
-8
ListCar.vue
src/components/hotel/list/ListCar.vue
+17
-4
ListHeader.vue
src/components/hotel/list/ListHeader.vue
+6
-4
dictionary.ts
src/config/dictionary.ts
+5
-0
HotelList.vue
src/pages/hotel/HotelList.vue
+2
-0
No files found.
src/components/hotel/list/ListCar.vue
View file @
d462445d
...
@@ -133,6 +133,7 @@ import { useQuasar } from 'quasar'
...
@@ -133,6 +133,7 @@ import { useQuasar } from 'quasar'
export
default
defineComponent
({
export
default
defineComponent
({
props
:
{},
props
:
{},
setup
(
props
,
context
)
{
setup
(
props
,
context
)
{
const
HotelLength
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_LENGTH
)
as
any
const
orderstatus
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_STATUS
)
as
any
const
orderstatus
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_STATUS
)
as
any
const
cars
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_LIST
)
as
any
const
cars
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_LIST
)
as
any
const
editor
=
inject
(
DirtionmaryHelper
.
HOTEL_UPDATEHOTEL_CAR
)
as
any
const
editor
=
inject
(
DirtionmaryHelper
.
HOTEL_UPDATEHOTEL_CAR
)
as
any
...
@@ -158,7 +159,7 @@ export default defineComponent({
...
@@ -158,7 +159,7 @@ export default defineComponent({
currentI
:
0
,
currentI
:
0
,
currentS
:
0
,
currentS
:
0
,
RemainingInventory
:
0
,
RemainingInventory
:
0
,
HotelLength
:
0
,
//
HotelLength: 0,
loading
:
false
,
loading
:
false
,
cacheHotels
:
[
cacheHotels
:
[
{
Name
:
t
(
'hotel.car.scattered'
),
ID
:
1
},
{
Name
:
t
(
'hotel.car.scattered'
),
ID
:
1
},
...
@@ -235,6 +236,7 @@ export default defineComponent({
...
@@ -235,6 +236,7 @@ export default defineComponent({
localStorage
.
removeItem
(
DirtionmaryHelper
.
HOTEL_HOTELCARS_CACHE
)
localStorage
.
removeItem
(
DirtionmaryHelper
.
HOTEL_HOTELCARS_CACHE
)
cars
.
value
=
[]
cars
.
value
=
[]
orderstatus
.
value
=
true
orderstatus
.
value
=
true
HotelLength
.
value
=
0
context
.
emit
(
'success'
)
context
.
emit
(
'success'
)
}
else
{
}
else
{
message
.
errorMsg
(
r
.
data
.
message
)
message
.
errorMsg
(
r
.
data
.
message
)
...
@@ -247,9 +249,9 @@ export default defineComponent({
...
@@ -247,9 +249,9 @@ export default defineComponent({
})
})
},
},
getLength
()
{
getLength
()
{
data
.
HotelLength
=
0
HotelLength
.
value
=
0
cars
.
value
.
forEach
((
item
:
any
)
=>
{
cars
.
value
.
forEach
((
item
:
any
)
=>
{
data
.
HotelLength
+=
item
.
Hotels
.
length
HotelLength
.
value
+=
item
.
Hotels
.
length
})
})
},
},
removeHotelHandler
(
x
:
number
,
y
:
number
){
removeHotelHandler
(
x
:
number
,
y
:
number
){
...
@@ -274,7 +276,18 @@ export default defineComponent({
...
@@ -274,7 +276,18 @@ export default defineComponent({
}
}
methods
.
getLength
()
methods
.
getLength
()
methods
.
getMoney
()
methods
.
getMoney
()
return
{
...
toRefs
(
data
),
cars
,
TCNumRef
,
ContactNameRef
,
ContactNumberRef
,
...
methods
,
moneyFormat
,
info
,
panning
,
rightColor
,}
return
{
...
toRefs
(
data
),
cars
,
TCNumRef
,
ContactNameRef
,
ContactNumberRef
,
moneyFormat
,
info
,
panning
,
rightColor
,
HotelLength
,
...
methods
}
}
}
})
})
</
script
>
</
script
>
...
...
src/components/hotel/list/ListHeader.vue
View file @
d462445d
...
@@ -68,6 +68,7 @@ import { DirtionmaryHelper } from '../../../config/dictionary'
...
@@ -68,6 +68,7 @@ import { DirtionmaryHelper } from '../../../config/dictionary'
export
default
defineComponent
({
export
default
defineComponent
({
components
:
{
svgIcon
,
ListCar
},
components
:
{
svgIcon
,
ListCar
},
setup
()
{
setup
()
{
const
HotelLength
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_LENGTH
)
as
any
const
cars
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_LIST
)
as
any
const
cars
=
inject
(
DirtionmaryHelper
.
HOTEL_CAR_LIST
)
as
any
const
$q
=
useQuasar
()
const
$q
=
useQuasar
()
const
qDateProxy
=
ref
(
null
)
as
any
const
qDateProxy
=
ref
(
null
)
as
any
...
@@ -89,7 +90,7 @@ export default defineComponent({
...
@@ -89,7 +90,7 @@ export default defineComponent({
cacheHotels
:
[]
as
Array
<
any
>
,
cacheHotels
:
[]
as
Array
<
any
>
,
hotelsRates
:
[]
as
Array
<
HotelRate
>
,
hotelsRates
:
[]
as
Array
<
HotelRate
>
,
canHide
:
false
,
canHide
:
false
,
HotelLength
:
0
//
HotelLength: 0
})
})
data
.
scrollStyle
=
useScrollModule
().
scrollStyle
data
.
scrollStyle
=
useScrollModule
().
scrollStyle
const
search
=
inject
(
DirtionmaryHelper
.
HOTEL_QUERY_PARAM
)
as
any
const
search
=
inject
(
DirtionmaryHelper
.
HOTEL_QUERY_PARAM
)
as
any
...
@@ -186,10 +187,10 @@ export default defineComponent({
...
@@ -186,10 +187,10 @@ export default defineComponent({
data
.
rightCarOpen
=
false
data
.
rightCarOpen
=
false
},
},
getLength
(){
getLength
(){
data
.
HotelLength
=
0
HotelLength
.
value
=
0
if
(
cars
.
value
.
length
>
0
){
if
(
cars
.
value
.
length
>
0
){
cars
.
value
.
forEach
((
item
:
any
)
=>
{
cars
.
value
.
forEach
((
item
:
any
)
=>
{
data
.
HotelLength
+=
item
.
Hotels
.
length
HotelLength
.
value
+=
item
.
Hotels
.
length
})
})
}
}
},
},
...
@@ -222,7 +223,8 @@ export default defineComponent({
...
@@ -222,7 +223,8 @@ export default defineComponent({
qNameProxy
,
qNameProxy
,
searchCnt
,
searchCnt
,
search
,
search
,
cars
cars
,
HotelLength
}
}
}
}
})
})
...
...
src/config/dictionary.ts
View file @
d462445d
...
@@ -48,5 +48,10 @@ class DirtionmaryHelper {
...
@@ -48,5 +48,10 @@ class DirtionmaryHelper {
* 酒店訂單確定下單狀態
* 酒店訂單確定下單狀態
*/
*/
static
readonly
HOTEL_CAR_ORDER_STATUS
=
"hotelcarorderstatus"
static
readonly
HOTEL_CAR_ORDER_STATUS
=
"hotelcarorderstatus"
/**
* 酒店訂單數量
*/
static
readonly
HOTEL_CAR_ORDER_LENGTH
=
"hotelcarorderlength"
}
}
export
{
userDictionmary
,
DirtionmaryHelper
}
export
{
userDictionmary
,
DirtionmaryHelper
}
src/pages/hotel/HotelList.vue
View file @
d462445d
...
@@ -50,6 +50,8 @@ export default defineComponent({
...
@@ -50,6 +50,8 @@ export default defineComponent({
provide
(
DirtionmaryHelper
.
HOTEL_UPDATEHOTEL_CAR
,
updateObj
)
provide
(
DirtionmaryHelper
.
HOTEL_UPDATEHOTEL_CAR
,
updateObj
)
const
orderstatus
=
ref
(
false
)
const
orderstatus
=
ref
(
false
)
provide
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_STATUS
,
orderstatus
)
provide
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_STATUS
,
orderstatus
)
const
HotelLength
=
ref
(
0
)
provide
(
DirtionmaryHelper
.
HOTEL_CAR_ORDER_LENGTH
,
HotelLength
)
const
menu
=
inject
(
DirtionmaryHelper
.
MENU_KEYS
)
as
any
const
menu
=
inject
(
DirtionmaryHelper
.
MENU_KEYS
)
as
any
menu
.
value
=
2
menu
.
value
=
2
...
...
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