Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
Athena
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
华国豪
Athena
Commits
a8743396
Commit
a8743396
authored
Sep 03, 2019
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
c1186b6f
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
136 additions
and
57 deletions
+136
-57
HotelDetail.vue
src/components/Hotel/HotelDetail.vue
+25
-7
HotelList.vue
src/components/Hotel/HotelList.vue
+1
-1
HotelSure.vue
src/components/Hotel/HotelSure.vue
+21
-2
OpHotelOrderDetail.vue
...ents/newPersonalCenter/block/model/OpHotelOrderDetail.vue
+89
-47
No files found.
src/components/Hotel/HotelDetail.vue
View file @
a8743396
...
...
@@ -533,6 +533,7 @@
<el-date-picker
class=
"HD_date_input"
v-model=
"SimilarMsg.arrivalDate"
style=
"width:190px;"
clear-icon=
""
size=
"small"
value-format=
"yyyy-MM-dd"
@
change=
"getDepartureDate"
:picker-options=
"pickerOptions0"
type=
"date"
placeholder=
""
>
...
...
@@ -542,6 +543,7 @@
size=
"small"
value-format=
"yyyy-MM-dd"
:picker-options=
"pickerOptions0"
@
change=
"getDepartureDate"
type=
"date"
placeholder=
""
>
</el-date-picker>
...
...
@@ -882,10 +884,16 @@ export default {
this
.
$viewer
=
viewer
;
},
bigImgShow
(
index
)
{
//if (num == 1) {
this
.
$viewer
.
view
(
index
)
this
.
$viewer
.
view
(
index
)
this
.
$viewer
.
show
();
//}
},
//获取结束日期不能等于开始
getDepartureDate
(){
var
arrivalDate
=
new
Date
(
this
.
SimilarMsg
.
arrivalDate
);
var
departureDate
=
new
Date
(
this
.
SimilarMsg
.
departureDate
);
if
(
arrivalDate
.
getTime
()
>=
departureDate
.
getTime
()){
this
.
SimilarMsg
.
departureDate
=
moment
(
this
.
SimilarMsg
.
arrivalDate
).
add
(
1
,
'days'
).
format
(
'YYYY-MM-DD'
)
}
},
//获取房型
getGradeType
(
type
)
{
...
...
@@ -922,9 +930,6 @@ export default {
},
changeImg
(){
this
.
images
=
[]
this
.
bigImgShow
()
},
getList
()
{
...
...
@@ -1245,6 +1250,7 @@ export default {
this
.
SimilarMsg
,
res
=>
{
if
(
res
.
data
.
resultCode
==
1
)
{
this
.
SimilarList
=
[];
if
(
Object
.
prototype
.
toString
.
call
(
res
.
data
.
data
.
roomRateDetails
)
==
"[object Object]"
...
...
@@ -1319,7 +1325,19 @@ export default {
},
//获取价格
getPrice
(
price
)
{
return
Math
.
ceil
(
price
/
this
.
JapanIncrease
);
//(chargeableRateInfoPerPersonForANightBySetCurrency/0.9975)*入住天数*入住人数
//天数
return
Math
.
ceil
(
price
/
this
.
JapanIncrease
)
*
(
this
.
auditNum
+
this
.
childNum
)
*
this
.
DateDiff
(
this
.
SimilarMsg
.
arrivalDate
,
this
.
SimilarMsg
.
departureDate
);
},
//获取相差天数
DateDiff
(
sDate1
,
sDate2
)
{
//sDate1和sDate2是2017-09-25格式
var
aDate
,
oDate1
,
oDate2
,
iDays
;
aDate
=
sDate1
.
split
(
"-"
);
oDate1
=
new
Date
(
aDate
[
1
]
+
'-'
+
aDate
[
2
]
+
'-'
+
aDate
[
0
]);
//转换为09-25-2017格式
aDate
=
sDate2
.
split
(
"-"
);
oDate2
=
new
Date
(
aDate
[
1
]
+
'-'
+
aDate
[
2
]
+
'-'
+
aDate
[
0
]);
iDays
=
parseInt
(
Math
.
abs
(
oDate1
-
oDate2
)
/
1000
/
60
/
60
/
24
);
//把相差的毫秒数转换为天数
return
iDays
;
},
//点击预订传递参数
bookHotel
(
roomOptionCd
){
...
...
src/components/Hotel/HotelList.vue
View file @
a8743396
...
...
@@ -611,7 +611,7 @@
地址:
{{
item
.
address
}}
</div>
<div
class=
"HL_ListPrice"
>
<span><label>
¥
</label>
{{
getPrice
(
item
.
lowrateBySetCurrency
)
}}
</span>
起
<span><label>
¥
</label>
{{
getPrice
(
item
.
lowrate
Total
BySetCurrency
)
}}
</span>
起
</div>
<input
type=
"button"
class=
"HL_ListBtn"
@
click=
"goHotelDetail(item,'HotelDetail')"
value=
"查看详情"
/>
</div>
...
...
src/components/Hotel/HotelSure.vue
View file @
a8743396
...
...
@@ -325,6 +325,15 @@
text-align
:
right
;
width
:
80px
;
}
.HotelSure
.HS_div2One
.el-input__inner
{
border-radius
:
0
;
}
.HotelSure
.HS_div3
.el-input__inner
{
border-radius
:
0
;
}
.HotelSure
.HS_div3
.el-textarea__inner
{
border-radius
:
0
;
}
</
style
>
...
...
@@ -1010,8 +1019,18 @@ export default {
this
.
sureMsg
.
roomOptionCd
=
this
.
msg
.
roomOptionCd
;
this
.
sureMsg
.
HotelName
=
this
.
dataList
.
hotelName
;
this
.
sureMsg
.
HotelPic
=
this
.
HotelImgUrl
;
//判断选择的人数与入住人数
let
Count1
=
0
this
.
sureMsg
.
roomGroup
.
forEach
(
x
=>
{
Count1
+=
x
.
roomMaleCount
+
x
.
roomFemaleCount
+
x
.
roomChildCount
})
let
Count2
=
0
;
Count2
=
this
.
auditNum
+
this
.
childNum
;
if
(
Count1
!=
Count2
){
this
.
Error
(
'入住人数与总入住数不匹配'
);
return
;
}
this
.
dataList
.
roomGroup
.
forEach
(
x
=>
{
this
.
sureMsg
.
roomGroup
.
forEach
(
j
=>
{
if
(
Object
.
prototype
.
toString
.
call
(
x
.
rateGroup
)
==
'[object Object]'
){
...
...
src/components/newPersonalCenter/block/model/OpHotelOrderDetail.vue
View file @
a8743396
...
...
@@ -14,7 +14,7 @@
.HS_RightList
{
width
:
388px
;
display
:
inline-block
;
margin
-left
:
20px
;
margin
:
20px
20px
0
0
;
height
:
auto
;
}
.HS_div1
{
...
...
@@ -53,14 +53,14 @@
overflow
:
hidden
;
padding-bottom
:
20px
;
}
.
HS
_bookTitle
{
.
OP
_bookTitle
{
padding-left
:
20px
;
width
:
100%
;
background-color
:
#EDF4FF
;
color
:
#111111
;
font-size
:
12px
;
font-weight
:
bold
;
height
:
29
px
;
height
:
50
px
;
display
:
flex
;
align-items
:
center
;
border-bottom
:
1px
solid
#E0E0E0
;
...
...
@@ -144,13 +144,13 @@
position
:
relative
;
border
:
1px
solid
#E0E0E0
;
}
.
HS
_bookTitle
span
{
.
OP
_bookTitle
span
{
color
:
#FFA835
;
font-size
:
12px
;
position
:
absolute
;
right
:
20px
;
}
.
HS
_bookTitle
span
i
{
.
OP
_bookTitle
span
i
{
position
:
relative
;
top
:
1px
;
margin-right
:
3px
;
...
...
@@ -189,8 +189,8 @@
width
:
100%
;
height
:
100%
;
}
.
HS
_HotelRight
{
height
:
14
8px
;
.
Op
_HotelRight
{
height
:
23
8px
;
padding
:
17px
20px
20px
20px
;
border
:
1px
solid
#E0E0E0
;
border-top
:
0
;
...
...
@@ -221,10 +221,6 @@
.f12
{
font-size
:
12px
;
}
.C9
{
color
:
#999999
;
margin-right
:
20px
;
}
.HS_RoomInfo
li
{
display
:
block
;
width
:
100%
;
...
...
@@ -326,14 +322,81 @@
.disBtn
:hover
{
opacity
:
1
;
}
.OP_Stitle
{
color
:
#888888
;
text-align
:
right
;
display
:
inline-block
;
width
:
50px
;
margin-right
:
20px
;
}
</
style
>
<
template
>
<div
class=
"HotelSure"
v-loading=
"loading"
>
<div
class=
"HS_RightList"
>
<!--
<div
class=
"HS_RightBtm"
>
<div
class=
"HS_RitTop"
>
<span
class=
"HS_RitTop_Left"
>
订单总额
</span>
<span
class=
"HS_RitPrice"
>
<i>
¥
</i>
{{
details
.
model
.
TotalPrice
}}
</span>
</div>
</div>
-->
<div
class=
"HS_RightTopImg"
>
<template
v-if=
"details"
>
<img
:src=
"details.model.HotelPic"
alt=
""
/>
</
template
>
</div>
<div
class=
"Op_HotelRight"
>
<div
class=
"HS_HtName"
>
{{details.model.HotelName}}
</div>
<div
class=
"HS_HAddress"
v-if=
"details.parmResult"
>
<img
src=
"../../../../assets/img/hotel/redAddress.png"
alt=
""
/>
{{details.parmResult.address}}
</div>
<ul
class=
"HS_RoomInfo"
>
<li>
<span
style=
"margin-right:20px;"
>
房型
</span>
<span
v-if=
"details.parmResult"
>
<
template
v-if=
"details.parmResult.roomType==1"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
单人间
</
template
>
<
template
v-if=
"details.parmResult.roomType==2"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
双人间
</
template
>
<
template
v-if=
"details.parmResult.roomType==3"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
大床房
</
template
>
<
template
v-if=
"details.parmResult.roomType==4"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
三人间
</
template
>
<
template
v-if=
"details.parmResult.roomType==5"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
四人间
</
template
>
<
template
v-if=
"details.parmResult.roomType==6"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
日式房
</
template
>
<
template
v-if=
"details.parmResult.roomType==7"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
日式+西式混合
</
template
>
<
template
v-if=
"details.parmResult.roomType==8"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
大床房(小型)
</
template
>
<
template
v-if=
"(details.parmResult.roomType==9||details.parmResult.roomType=='')&&details.parmResult.gradeType==''"
>
未知房型
</
template
>
</span>
</li>
<li>
<span
style=
"margin-right:20px;"
>
吸烟
</span>
<
template
v-if=
"details.parmResult"
>
<span
v-if=
"details.parmResult.smoking==0"
>
禁烟
</span>
<span
v-if=
"details.parmResult.smoking==1"
>
可吸烟
</span>
</
template
>
</li>
<li>
<span
style=
"margin-right:20px;"
>
厕所
</span>
<
template
v-if=
"details.parmResult"
>
<span
v-if=
"details.parmResult.withBath==0"
>
无
</span>
<span
v-if=
"details.parmResult.withBath==1"
>
有
</span>
</
template
>
</li>
<li>
<span
style=
"margin-right:20px;"
>
露天客房
</span>
<
template
v-if=
"details.parmResult"
>
<span
v-if=
"details.parmResult.withOpenAirBath==0"
>
无
</span>
<span
v-if=
"details.parmResult.withOpenAirBath==1"
>
有
</span>
</
template
>
</li>
</ul>
</div>
</div>
<div
class=
"HS_LeftInfo"
>
<div
class=
"HS_div2"
>
<div
class=
"
HS
_bookTitle"
>
预订信息
</div>
<div
class=
"
OP
_bookTitle"
>
预订信息
</div>
<div
class=
"HS_div3One"
>
<ul>
<li
class=
"HS2_title"
>
订单号
</li>
...
...
@@ -344,7 +407,7 @@
<ul>
<li
class=
"HS2_title"
>
房型信息
</li>
<li>
<div>
<div
v-if=
"details.parmResult"
>
<
template
v-if=
"details.parmResult.roomType==1"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
单人间
</
template
>
<
template
v-if=
"details.parmResult.roomType==2"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
双人间
</
template
>
<
template
v-if=
"details.parmResult.roomType==3"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
大床房
</
template
>
...
...
@@ -353,6 +416,7 @@
<
template
v-if=
"details.parmResult.roomType==6"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
日式房
</
template
>
<
template
v-if=
"details.parmResult.roomType==7"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
日式+西式混合房
</
template
>
<
template
v-if=
"details.parmResult.roomType==8"
>
{{
getGradeType
(
details
.
parmResult
.
gradeType
)
}}
大床房(小型)
</
template
>
<
template
v-if=
"(details.parmResult.roomType==9||details.parmResult.roomType=='')&&details.parmResult.gradeType==''"
>
未知房型
</
template
>
</div>
</li>
</ul>
...
...
@@ -361,9 +425,9 @@
<ul>
<li
class=
"HS2_title"
>
入住日期
</li>
<li>
<span>
{{details.model.CheckIn.split('T')[0]}}
</span>
<span
v-if=
"details.model.CheckIn"
>
{{details.model.CheckIn.split('T')[0]}}
</span>
<div
class=
"HS_Line"
></div>
<span>
{{details.model.CheckOut.split('T')[0]}}
</span>
<span
v-if=
"details.model.CheckOut"
>
{{details.model.CheckOut.split('T')[0]}}
</span>
</li>
</ul>
</div>
...
...
@@ -377,56 +441,33 @@
</div>
</div>
<div
class=
"HS_div3"
>
<div
class=
"
HS
_bookTitle"
>
<div
class=
"
OP
_bookTitle"
>
入住信息
<span></span>
</div>
<div>
<div
v-if=
"details.parmResult"
style=
"font-size:12px;"
>
<div>
<label
class=
"
HS2_title"
>
预订人:
</label>
<label
class=
"
OP_Stitle"
>
预订人
</label>
<div>
{{details.parmResult.guestLastName + details.parmResult.guestFirstName}}
</div>
</div>
<div>
<label
class=
"
HS2_title"
>
当前地址:
</label>
<label
class=
"
OP_Stitle"
>
当前地址
</label>
<div>
{{details.parmResultRoomInfo.guestAddress}}
</div>
</div>
<div>
<label
class=
"
HS2_title"
>
Email:
</label>
<label
class=
"
OP_Stitle"
>
Email
</label>
<div>
{{details.parmResultRoomInfo.guestEmail}}
</div>
</div>
<div>
<label
class=
"
HS2_title"
>
电话:
</label>
<label
class=
"
OP_Stitle"
>
电话
</label>
<div>
{{details.parmResultRoomInfo.guestPhoneNumber}}
</div>
</div>
<div>
<label
class=
"
HS2_title"
>
客户备注:
</label>
<div>
{{details.model.Remark}}
</div>
<label
class=
"
OP_Stitle"
>
客户备注
</label>
<div
style=
"width:90%"
>
{{details.model.Remark}}
</div>
</div>
</div>
</div>
</div>
<div
class=
"HS_RightList"
>
<div
class=
"HS_RightBtm"
>
<div
class=
"HS_RitTop"
>
<span
class=
"HS_RitTop_Left"
>
订单总额
</span>
<span
class=
"HS_RitPrice"
>
<i>
¥
</i>
{{details.model.TotalPrice}}
</span>
</div>
</div>
<div
class=
"HS_RightTopImg"
>
<
template
v-if=
"details"
>
<img
:src=
"details.model.HotelPic"
alt=
""
/>
</
template
>
</div>
<div
class=
"HS_HotelRight"
>
<div
class=
"HS_HtName"
>
{{details.model.HotelName}}
</div>
<div
class=
"HS_HAddress"
>
<img
src=
"../../../../assets/img/hotel/redAddress.png"
alt=
""
/>
{{details.parmResult.address}}
</div>
</div>
</div>
</div>
</template>
<
script
>
...
...
@@ -453,7 +494,8 @@ export default {
this
.
loading
=
false
;
if
(
res
.
data
.
resultCode
==
1
)
{
let
data
=
res
.
data
.
data
this
.
details
=
data
this
.
details
=
data
;
console
.
log
(
this
.
details
,
'detailsssss'
);
}
else
{
this
.
Error
(
res
.
data
.
message
);
}
...
...
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