Commit 9c77d820 authored by 黄奎's avatar 黄奎

11

parent 1fea54c6
...@@ -3,24 +3,29 @@ ...@@ -3,24 +3,29 @@
<view style="padding: 0 31rpx;"> <view style="padding: 0 31rpx;">
<view class="hotelDetailBox activeTag" v-for="(item,index) in RoomList" :key="index"> <view class="hotelDetailBox activeTag" v-for="(item,index) in RoomList" :key="index">
<view class="hotelDetailTag"> <view class="hotelDetailTag">
热门房型 {{item.RoomName_CN}}
</view> </view>
<template v-for="(subItem,subindex) in item.RatePlanList"> <template v-for="(subItem,subindex) in item.RatePlanList">
<view class="hotelDetail row" v-if="!subindex"> <view class="hotelDetail row" v-if="!subindex">
<view class="hotelDetailL" @click="openPicture(item.images)"> <template v-if="item.images&&item.images.length>0">
<image mode="heightFix" :src="item.Path" /> <view class="hotelDetailL" @click="openPicture(item.images)">
<view class="hotelDetailLImgs" v-if="item.images&&item.images.length>1"> <image mode="heightFix" :src="item.images[0].Url" />
{{ item.images.length }} <view class="hotelDetailLImgs" v-if="item.images&&item.images.length>1">
{{ item.images.length }}
</view>
</view> </view>
</view> </template>
<template v-else>
<view class="hotelDetailL">
<image mode="heightFix"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Static/defaultHotelImg.png" />
</view>
</template>
<view class="hotelDetailR column"> <view class="hotelDetailR column">
<view class="hotelDetailRTitle row items-center"> <view class="hotelDetailRTitle row items-center">
<view> <view>
<!--
{{ getRoomType(subItem.BedType) }}-->
</view> </view>
<!--
<img :src="openImg[0]" />-->
</view> </view>
<view class="hotelDetailRRoom"> <view class="hotelDetailRRoom">
{{ subItem.RoomName_CN }} {{ subItem.RoomName_CN }}
...@@ -287,17 +292,23 @@ ...@@ -287,17 +292,23 @@
return mealtypeName; return mealtypeName;
}, },
goUrl(subItem) { goUrl(subItem) {
let HotelInfo = { let pHotel = {
hotelid: this.HotelInfo.hotelid, hotelid: this.HotelInfo.hotelid,
name: this.HotelInfo.name, name: this.HotelInfo.name,
location: this.HotelInfo.location, address: "",
address: this.HotelInfo.address, images: [],
destination: this.HotelInfo.destination, }
country: this.HotelInfo.country, if (this.HotelInfo) {
images: this.HotelInfo.images, if (this.HotelInfo.images && this.HotelInfo.images.length > 0) {
//pHotel.images = this.HotelInfo.images;
}
if (this.HotelInfo.address) {
pHotel.address = this.HotelInfo.address;
}
} }
console.log("hotelRoom", pHotel);
uni.navigateTo({ uni.navigateTo({
url: `/pages/hotel/order?searchObj=${JSON.stringify(this.searchObj)}&dayObj=${JSON.stringify(this.dayObj)}&HotelInfo=${JSON.stringify(HotelInfo)}&RoomInfo=${JSON.stringify(subItem)}`, url: `/pages/hotel/order?searchObj=${JSON.stringify(this.searchObj)}&dayObj=${JSON.stringify(this.dayObj)}&HotelInfo=${JSON.stringify(pHotel)}&RoomInfo=${JSON.stringify(subItem)}`,
}); });
}, },
openPicture(item) { openPicture(item) {
......
...@@ -16,19 +16,12 @@ ...@@ -16,19 +16,12 @@
style="width: 37rpx; height: 44rpx" mode=""></image> style="width: 37rpx; height: 44rpx" mode=""></image>
</view> </view>
</view> </view>
<!-- <view class="type-box" v-if="videoUrl!=''">
<u-tabs bg-color="rgba(0,0,0,0)" :is-scroll="false" name="Name" :list="typeList"
:active-color="mainColor" :current="active" @change="changeHandler" :show-bar="true"
:bold="false" height="50" duration="0" font-size="24" :activeFontSize="24" :typeStyle="2">
</u-tabs>
</view> -->
<view class="media-info" v-if="dataList.images"> <view class="media-info" v-if="dataList.images">
<view class="flex"> <view class="flex">
<view class="mi-left"> <view class="mi-left">
<view v-if="dataList.images.length > 0" class="type-img-box"> <view v-if="dataList.images.length > 0" class="type-img-box">
<image :src="dataList.images[0].url" mode="aspectFill"></image> <image :src="dataList.images[0].url" mode="aspectFill"></image>
<view class="content"> <view class="content">
<!-- <u-icon name="photo" size="26" color="#FFF"></u-icon> -->
<text>{{ dataList.images.length }}</text> <text>{{ dataList.images.length }}</text>
</view> </view>
</view> </view>
...@@ -205,8 +198,6 @@ ...@@ -205,8 +198,6 @@
<hotelPolicy ref="hotelPolicy" id="hotelPolicy" :dataList="dataList"></hotelPolicy> <hotelPolicy ref="hotelPolicy" id="hotelPolicy" :dataList="dataList"></hotelPolicy>
<hotelFacilities ref="hotelFacilities" id="hotelFacilities" :dataList="dataList"> <hotelFacilities ref="hotelFacilities" id="hotelFacilities" :dataList="dataList">
</hotelFacilities> </hotelFacilities>
</view> </view>
</view> </view>
</view> </view>
...@@ -486,7 +477,6 @@ ...@@ -486,7 +477,6 @@
if (options.searchObj) { if (options.searchObj) {
this.searchObj = JSON.parse(options.searchObj); this.searchObj = JSON.parse(options.searchObj);
} }
// this.getRecomHotel();
this.getHotelPrices() this.getHotelPrices()
this.getdidaMealType() this.getdidaMealType()
}, },
...@@ -564,29 +554,20 @@ ...@@ -564,29 +554,20 @@
console.log("dmc_post_GetDiDaPriceSearchList", tempData); console.log("dmc_post_GetDiDaPriceSearchList", tempData);
this.DidaHotelRoomDetails = tempData; this.DidaHotelRoomDetails = tempData;
this.qRoomTypeList = tempData.qRoomTypeList; this.qRoomTypeList = tempData.qRoomTypeList;
this.qRoomTypeList.unshift({ if (this.qRoomTypeList && this.qRoomTypeList.length > 0) {
RoomTypeID: -1, this.qRoomTypeList.unshift({
RoomName_CN: '全部' RoomTypeID: -1,
}) RoomName_CN: '房型(全部)'
var tempMealArray = tempData.qMealTypeList; })
if (tempMealArray && tempMealArray.length > 0) { }
tempMealArray.forEach(mItem => { this.qMealTypeList = tempData.qMealTypeList;
var MTypeName = that.getMealtype(mItem if (this.qMealTypeList && this.qMealTypeList.length > 0) {
.MealType); this.qMealTypeList.unshift({
if (mItem.MealAmount > 0) { MTypeName: "餐型(全部)",
MTypeName += mItem.MealAmount + MealAmount: 0,
"份"; MealType: 0,
} })
mItem.MTypeName = MTypeName
});
} }
this.qMealTypeList = tempMealArray;
this.qMealTypeList.unshift({
MTypeName: "全部",
MealAmount: 0,
MealType: 0,
})
} }
}) })
}, },
...@@ -629,7 +610,6 @@ ...@@ -629,7 +610,6 @@
}, },
(res) => { (res) => {
if (res.resultCode == 1) { if (res.resultCode == 1) {
// console.log(res, '推荐酒店');
this.HotelArr = []; this.HotelArr = [];
let tempHotel = res.data.pageData; let tempHotel = res.data.pageData;
tempHotel.forEach((x) => { tempHotel.forEach((x) => {
...@@ -786,9 +766,7 @@ ...@@ -786,9 +766,7 @@
longPressActions: { longPressActions: {
itemList: ["发送给朋友", "保存图片", "收藏"], itemList: ["发送给朋友", "保存图片", "收藏"],
success: function(data) {}, success: function(data) {},
fail: function(err) { fail: function(err) {},
// console.log(err.errMsg);
},
}, },
}); });
}, },
...@@ -844,20 +822,8 @@ ...@@ -844,20 +822,8 @@
for (let i = 0; i < res.data.images.length; i++) { for (let i = 0; i < res.data.images.length; i++) {
res.data.images[i].Path = res.data.images[i].url res.data.images[i].Path = res.data.images[i].url
} }
// for(let i=0;i<res.data.rooms.length;i++){
// let list = res.data.rooms[i].images.filter(x=>{
// return x.isDefault
// })
// res.data.rooms[i].images.forEach(x=>{
// x.Path = x.url
// })
// if(list.length>0) res.data.rooms[i].Path = list[0].url
// else res.data.rooms[i].Path = res.data.rooms[i].images.length>0&&res.data.rooms[i].images[0].url?res.data.rooms[i].images[0].url:''
// this.RoomList.push(res.data.rooms[i])
// }
this.hotelData.hotelid = this.dataList.hotelid; this.hotelData.hotelid = this.dataList.hotelid;
this.hotelData.name = this.dataList.name; this.hotelData.name = this.dataList.name;
// this.hotelData.Booking = this.dataList.Booking;
setTimeout(() => { setTimeout(() => {
this.hotelFacilities.forEach((x) => { this.hotelFacilities.forEach((x) => {
const query = uni.createSelectorQuery().select(`#${x.val}`); const query = uni.createSelectorQuery().select(`#${x.val}`);
...@@ -868,35 +834,6 @@ ...@@ -868,35 +834,6 @@
}, 1000); }, 1000);
} }
}) })
// let msg = {
// hotelid: id,
// StartDate: this.dayObj.start,
// EndDate: this.dayObj.end,
// };
// this.request2(
// {
// url: "/api/Hotel/GetHotelInfo",
// data: msg,
// },
// (res) => {
// if (res.resultCode == 1) {
// // console.log(res, '详情数据');
// this.dataList = res.data;
// this.RoomList = this.dataList.RoomList;
// this.hotelData.hotelid = this.dataList.hotelid;
// this.hotelData.name = this.dataList.name;
// this.hotelData.Booking = this.dataList.Booking;
// setTimeout(() => {
// this.hotelFacilities.forEach((x)=>{
// const query = uni.createSelectorQuery().select(`#${x.val}`);
// query.boundingClientRect((rect) => {
// x.top = rect.top+250;
// }).exec();
// })
// }, 1000);
// }
// }
// );
}, },
// #ifdef MP-WEIXIN // #ifdef MP-WEIXIN
//分享朋友圈 //分享朋友圈
......
...@@ -42,15 +42,6 @@ ...@@ -42,15 +42,6 @@
pageIndex: 1, pageIndex: 1,
pageSize: 15, pageSize: 15,
KeyWords: "", //关键字 KeyWords: "", //关键字
// StartPrice: 0,
// EndPrice: 1000,
// QStartDate: "",//开始日期
// QEndDate: "",//结束日期
// OrderByType: "1", //排序类型
// QStars: "", //星级
// TagList: [], //查询标签
// City: 262, //市
// District: 0, //区
}, },
HotelList: [], //酒店数据 HotelList: [], //酒店数据
tempRateAndPrice: { tempRateAndPrice: {
...@@ -247,13 +238,10 @@ ...@@ -247,13 +238,10 @@
} }
.hotel-list .hotel-city { .hotel-list .hotel-city {
// width: 105rpx;
height: 40rpx; height: 40rpx;
padding: 0rpx 0 8rpx 0rpx; padding: 0rpx 0 8rpx 0rpx;
margin-right: 27rpx; margin-right: 27rpx;
text-align: center; text-align: center;
/* color: #DFBE6E; */
// border-right: 1px solid #e2e2e2;
font-size: 28rpx; font-size: 28rpx;
white-space: nowrap; white-space: nowrap;
overflow: hidden; overflow: hidden;
...@@ -273,7 +261,6 @@ ...@@ -273,7 +261,6 @@
} }
.hotel-list .search-box .date { .hotel-list .search-box .date {
// width: 82rpx;
height: 50rpx; height: 50rpx;
font-size: 20rpx; font-size: 20rpx;
font-weight: 500; font-weight: 500;
......
This diff is collapsed.
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