Commit 8f4f709b authored by zhengke's avatar zhengke

修改

parent 1cab2ce5
......@@ -562,7 +562,7 @@
</el-col>
</el-row>
<!-- 酒店 -->
<div class="Grouptour hotel">
<div class="Grouptour hotel" style="height:390px;overflow:hidden;">
<div class="tour_left">
<p>酒店</p>
<div class="tour_left_content hotel_left_content">
......@@ -1275,18 +1275,32 @@ export default {
searchMinRate: 0,
searchRoomType: [],
searchroomGroup: [{roomNum: 1, numberOfAdults: 1, numberOfChildren: 0, childAges: 0}],
sort: 0
sort: 1
}
this.hotelLoading=true;
var hotelData = [];
this.HotelList=[];
this.apipost("dmc_post_Get_GetJAPAN_HotelList",msg,res => {
this.hotelLoading=false;
if (res.data.resultCode == 1) {
if(Object.prototype.toString.call(res.data.data.hotelSummary) == '[object Object]'){
this.HotelList.push(res.data.data.hotelSummary);
}else{
this.HotelList = res.data.data.hotelSummary;
if(res.data.data.parmResult && res.data.data.parmResult.hotelSummary){
hotelData = res.data.data.parmResult.hotelSummary;
}
var ourHotelList = res.data.data.ourHotelList;
if (ourHotelList && ourHotelList.length > 0) {
ourHotelList.forEach(x => {
x.type = 2
})
}
if (hotelData && hotelData.length > 0) {
//获取酒店坐标
hotelData.forEach(x => {
x.type = 1
})
}
this.PassMsg.groupBookingFlg = res.data.data.groupBookingFlg;
this.HotelList = ourHotelList.concat(hotelData);
this.PassMsg.groupBookingFlg = res.data.data.parmResult.groupBookingFlg;
} else {
this.Error(res.data.message);
}
......@@ -1352,23 +1366,61 @@ export default {
},
//跳转详情
goHotelDetail(item){
this.PassMsg.hotelId = item.hotelId,
this.PassMsg.arrivalDate=moment().format("YYYY-MM-DD");
this.PassMsg.departureDate = moment().add(1,'days').format('YYYY-MM-DD');
this.PassMsg.searchroomGroup = [{
roomNum:1,
numberOfAdults:1,
numberOfChildren:0,
childAges:0
}],
this.PassMsg.lowrateBySetCurrency = item.lowrateBySetCurrency;
if (item.type == 2) {
let routeData = this.$router.resolve({
name: "SupplierView",
query: {
HotelId: item.hotelId,
arrivalDate: moment().format("YYYY-MM-DD"),
departureDate: moment().add(1,'days').format('YYYY-MM-DD')
}
});
window.open(routeData.href, "_blank");
} else {
this.PassMsg.hotelId = item.hotelId,
this.PassMsg.arrivalDate = moment().format("YYYY-MM-DD");
this.PassMsg.departureDate = moment().add(1,'days').format('YYYY-MM-DD');
this.PassMsg.searchroomGroup = [
{
roomNum:1,
numberOfAdults:1,
numberOfChildren:0,
childAges:0
}
];
this.PassMsg.lowrateBySetCurrency = item.lowrateBySetCurrency;
this.PassMsg.room = 1
this.PassMsg.auditNum = 1;
sessionStorage.setItem("HotelDetail", JSON.stringify(this.PassMsg));
var jsonstr = JSON.stringify(this.PassMsg);
let routeData = this.$router.resolve({
name: "HotelDetail",
query: {
msg: encodeURIComponent(jsonstr),
}
});
window.open(routeData.href, "_blank");
}
// this.PassMsg.hotelId = item.hotelId,
// this.PassMsg.arrivalDate=moment().format("YYYY-MM-DD");
// this.PassMsg.departureDate = moment().add(1,'days').format('YYYY-MM-DD');
// this.PassMsg.searchroomGroup = [{
// roomNum:1,
// numberOfAdults:1,
// numberOfChildren:0,
// childAges:0
// }],
// this.PassMsg.lowrateBySetCurrency = item.lowrateBySetCurrency;
this.PassMsg.room = 1
// this.PassMsg.room = 1
sessionStorage.setItem("HotelDetail", JSON.stringify(this.PassMsg));
this.$router.push({
path:"/HotelDetail"
})
// sessionStorage.setItem("HotelDetail", JSON.stringify(this.PassMsg));
// this.$router.push({
// path:"/HotelDetail"
// })
},
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment