|
@@ -9,7 +9,7 @@
|
|
|
<text class="uni-title">墨轩湖姬子公寓(南昌交通学院)</text>
|
|
<text class="uni-title">墨轩湖姬子公寓(南昌交通学院)</text>
|
|
|
<text class="uni-sub-title">2021年装修 | 智能门锁 | 房间wifi | 免费停车</text>
|
|
<text class="uni-sub-title">2021年装修 | 智能门锁 | 房间wifi | 免费停车</text>
|
|
|
<text class="uni-extra" @click="navigateToXiangqing">设施/详情></text>
|
|
<text class="uni-extra" @click="navigateToXiangqing">设施/详情></text>
|
|
|
- <text class="uni-body">宜春市靖安县北高速路口什么路899号</text>
|
|
|
|
|
|
|
+ <text class="uni-body">江西省宜春市靖安县墨轩湖大道1号</text>
|
|
|
<image class="uni-phone" @click="telphone(phone)" src="../../static/index/index_phone.svg"></image>
|
|
<image class="uni-phone" @click="telphone(phone)" src="../../static/index/index_phone.svg"></image>
|
|
|
<a href="https://uri.amap.com/marker?position=115.387261,28.788671&name=南昌交通学院智慧公寓">
|
|
<a href="https://uri.amap.com/marker?position=115.387261,28.788671&name=南昌交通学院智慧公寓">
|
|
|
<image class="uni-map" @click="mapDaohang('115.387261','28.788671')" src="../../static/index/index_map.svg"></image>
|
|
<image class="uni-map" @click="mapDaohang('115.387261','28.788671')" src="../../static/index/index_map.svg"></image>
|
|
@@ -22,7 +22,7 @@
|
|
|
<image src="../../static/index/xuzhi.png" class="img-btn" height="100%" width="100%"></image>
|
|
<image src="../../static/index/xuzhi.png" class="img-btn" height="100%" width="100%"></image>
|
|
|
<text class="list-txt">入住须知</text>
|
|
<text class="list-txt">入住须知</text>
|
|
|
</view>
|
|
</view>
|
|
|
- <view class="item-list-one" @click="navigateToDairuzhu">
|
|
|
|
|
|
|
+ <view class="item-list-one" @click="navigateToDairuzhu('warn')">
|
|
|
<image src="../../static/index/ruzhu.png" class="img-btn"></image>
|
|
<image src="../../static/index/ruzhu.png" class="img-btn"></image>
|
|
|
<text class="list-txt">办理入住</text>
|
|
<text class="list-txt">办理入住</text>
|
|
|
</view>
|
|
</view>
|
|
@@ -30,16 +30,20 @@
|
|
|
<image src="../../static/index/index_xuzhu.svg" class="img-btn"></image>
|
|
<image src="../../static/index/index_xuzhu.svg" class="img-btn"></image>
|
|
|
<text class="list-txt">办理续住</text>
|
|
<text class="list-txt">办理续住</text>
|
|
|
</view> -->
|
|
</view> -->
|
|
|
- <view class="item-list-one" @click="navigateToTuifang">
|
|
|
|
|
|
|
+ <view class="item-list-one" @click="navigateToTuifang('warn')">
|
|
|
<image src="../../static/index/tuifang.png" class="img-btn"></image>
|
|
<image src="../../static/index/tuifang.png" class="img-btn"></image>
|
|
|
<text class="list-txt">办理退房</text>
|
|
<text class="list-txt">办理退房</text>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
<!-- 退房失败时弹框 -->
|
|
<!-- 退房失败时弹框 -->
|
|
|
- <uni-popup ref="popup_tui" type="center" width="300rpx" height="300rpx" background-color="#fff">
|
|
|
|
|
- <view class="kuang_txt">
|
|
|
|
|
|
|
+ <!-- <uni-popup ref="popup_tui" type="center" width="300rpx" height="300rpx" background-color="#fff">
|
|
|
|
|
+ <view class="kuang_txt_tui">
|
|
|
<text>请先订房</text>
|
|
<text>请先订房</text>
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+ </uni-popup> -->
|
|
|
|
|
+ <uni-popup ref="popup_tui" type="dialog">
|
|
|
|
|
+ <uni-popup-dialog :type="msgType" cancelText="关闭" confirmText="确定" content="请先订房!" @confirm="dialogConfirm"
|
|
|
|
|
+ @close="dialogClose"></uni-popup-dialog>
|
|
|
</uni-popup>
|
|
</uni-popup>
|
|
|
<!-- 第三层订房 -->
|
|
<!-- 第三层订房 -->
|
|
|
<view class="room-list">
|
|
<view class="room-list">
|
|
@@ -90,6 +94,16 @@
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
</view>
|
|
</view>
|
|
|
|
|
+ <!-- 订房时弹框 -->
|
|
|
|
|
+ <!-- <uni-popup ref="popup_order" type="center" width="300rpx" height="300rpx" background-color="#fff">
|
|
|
|
|
+ <view class="kuang_txt">
|
|
|
|
|
+ <text>{{order_txt}}</text>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </uni-popup> -->
|
|
|
|
|
+ <uni-popup ref="popup_order" type="dialog">
|
|
|
|
|
+ <uni-popup-dialog :type="msgType" cancelText="关闭" confirmText="确定" :content="order_txt" @confirm="dialogConfirm"
|
|
|
|
|
+ @close="dialogClose"></uni-popup-dialog>
|
|
|
|
|
+ </uni-popup>
|
|
|
<!-- 房间样式弹窗页面 -->
|
|
<!-- 房间样式弹窗页面 -->
|
|
|
<uni-popup ref="popup" type="dialog" :mask-click="false">
|
|
<uni-popup ref="popup" type="dialog" :mask-click="false">
|
|
|
<view class="popup_bg">
|
|
<view class="popup_bg">
|
|
@@ -104,7 +118,7 @@
|
|
|
</swiper-item>
|
|
</swiper-item>
|
|
|
</swiper>
|
|
</swiper>
|
|
|
<text class="popup_title2">便利设施</text>
|
|
<text class="popup_title2">便利设施</text>
|
|
|
- <view class="popup_txt">{{typeText}}</view>
|
|
|
|
|
|
|
+ <view class="popup_txt"><view class="popup_txt_in">{{typeText}}</view></view>
|
|
|
</view>
|
|
</view>
|
|
|
</uni-popup>
|
|
</uni-popup>
|
|
|
<!-- 有一个可续住订单时办理续住弹窗页面 -->
|
|
<!-- 有一个可续住订单时办理续住弹窗页面 -->
|
|
@@ -201,6 +215,7 @@
|
|
|
date:'',
|
|
date:'',
|
|
|
endDate:''
|
|
endDate:''
|
|
|
},
|
|
},
|
|
|
|
|
+ msgType: 'warn',
|
|
|
distance: 0, //"距离"
|
|
distance: 0, //"距离"
|
|
|
startTime:'',//默认到店日期
|
|
startTime:'',//默认到店日期
|
|
|
endTime:'',//默认离店日期
|
|
endTime:'',//默认离店日期
|
|
@@ -232,7 +247,12 @@
|
|
|
markers: [],
|
|
markers: [],
|
|
|
markerHeight: 30,
|
|
markerHeight: 30,
|
|
|
xuzhu_type:[],// 办理续住判断条件
|
|
xuzhu_type:[],// 办理续住判断条件
|
|
|
- xuzhu_panduan:[]// 办理续住判断条件赋值
|
|
|
|
|
|
|
+ xuzhu_panduan:[],// 办理续住判断条件赋值
|
|
|
|
|
+ tui_type:[],// 办理退房判断条件
|
|
|
|
|
+ tui_panduan:[],// 办理退房判断条件赋值
|
|
|
|
|
+ dai_type:[],// 办理入住判断条件
|
|
|
|
|
+ dai_panduan:[],// 办理入住判断条件赋值
|
|
|
|
|
+ order_txt:'',//订房事故时信息
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
onLoad() {
|
|
onLoad() {
|
|
@@ -356,6 +376,8 @@
|
|
|
getOrderPage() {
|
|
getOrderPage() {
|
|
|
let _self = this
|
|
let _self = this
|
|
|
_self.xuzhu_type=[]
|
|
_self.xuzhu_type=[]
|
|
|
|
|
+ _self.tui_type=[]
|
|
|
|
|
+ _self.dai_type=[]
|
|
|
this.$axios.get("/ihotel/hotelOrder/user/order/page?curPage=1&pageSize=100",
|
|
this.$axios.get("/ihotel/hotelOrder/user/order/page?curPage=1&pageSize=100",
|
|
|
{
|
|
{
|
|
|
headers:{
|
|
headers:{
|
|
@@ -367,6 +389,8 @@
|
|
|
res.data.list.forEach(data => {
|
|
res.data.list.forEach(data => {
|
|
|
if (data.flag !== '-1') {
|
|
if (data.flag !== '-1') {
|
|
|
_self.xuzhu_type.push(data.orderStatu)
|
|
_self.xuzhu_type.push(data.orderStatu)
|
|
|
|
|
+ _self.tui_type.push(data.orderStatu)
|
|
|
|
|
+ _self.dai_type.push(data.orderStatu)
|
|
|
// console.log(_self.xuzhu_type)
|
|
// console.log(_self.xuzhu_type)
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
@@ -392,51 +416,60 @@
|
|
|
navigateToOrderRoom(enableNum,id,typeName) {
|
|
navigateToOrderRoom(enableNum,id,typeName) {
|
|
|
let _self = this
|
|
let _self = this
|
|
|
_self.roomType = []
|
|
_self.roomType = []
|
|
|
- this.$axios.get("/ihotel/hotelOrder/user/order/confirm?startTime="+this.startDate.substring(0,10)+"&endTime="+this.endDate.substring(0,10)+'&roomTypeId='+id).then(res => {
|
|
|
|
|
- res = res.data
|
|
|
|
|
- if (res.success) {
|
|
|
|
|
- // console.log(res)
|
|
|
|
|
- this.payMount=res.data.totalAmount
|
|
|
|
|
- this.freeRoom=res.data.freeNum
|
|
|
|
|
- this.ruzhu_num=res.data.nums
|
|
|
|
|
- if (enableNum>=1){
|
|
|
|
|
- uni.navigateTo({
|
|
|
|
|
- url: "../order_room/order_room?roomTypeId="+id +"&enableStartTime="+this.startDate+"&enableEndTime="+this.endDate+"&startTime="+this.startTime+"&endTime="+this.endTime+"&typeName="+typeName+"&payMount="+this.payMount+"&freeRoom="+this.freeRoom+'&ruzhu_num='+this.ruzhu_num,
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
- this.getRoomType()
|
|
|
|
|
- } else {
|
|
|
|
|
- alert(res.message)
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ if (enableNum>=1){
|
|
|
|
|
+ uni.navigateTo({
|
|
|
|
|
+ url: "../order_room/order_room?roomTypeId="+id +"&enableStartTime="+this.startDate+"&enableEndTime="+this.endDate+"&startTime="+this.startTime+"&endTime="+this.endTime+"&typeName="+typeName,
|
|
|
|
|
+ });
|
|
|
|
|
+ }
|
|
|
|
|
+ this.getRoomType()
|
|
|
|
|
|
|
|
|
|
|
|
|
},
|
|
},
|
|
|
//办理入住跳转
|
|
//办理入住跳转
|
|
|
- navigateToDairuzhu(){
|
|
|
|
|
- uni.navigateTo({
|
|
|
|
|
- url: "../my_orderlist/my_orderlist?Inv=2",
|
|
|
|
|
- })
|
|
|
|
|
|
|
+ navigateToDairuzhu(type){
|
|
|
|
|
+ this.dai_panduan=[]
|
|
|
|
|
+ setTimeout(() => {
|
|
|
|
|
+ this.getOrderPage()
|
|
|
|
|
+ },1)
|
|
|
|
|
+ setTimeout(() => {
|
|
|
|
|
+ for (let i=0;i<this.dai_type.length;i++){
|
|
|
|
|
+ this.dai_type.forEach(val => {
|
|
|
|
|
+ if(val[i]==2) {
|
|
|
|
|
+ this.dai_panduan.push(val)
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ }
|
|
|
|
|
+ if(this.dai_panduan.length>=1) {
|
|
|
|
|
+ uni.navigateTo({
|
|
|
|
|
+ url:"../my_orderlist/my_orderlist?Inv=2"
|
|
|
|
|
+ })
|
|
|
|
|
+ }else if(this.dai_panduan.length<1) {
|
|
|
|
|
+ this.msgType = type
|
|
|
|
|
+ this.order_txt='请先订房!'
|
|
|
|
|
+ this.$refs.popup_order.open()
|
|
|
|
|
+ }
|
|
|
|
|
+ },150)
|
|
|
},
|
|
},
|
|
|
//办理退房
|
|
//办理退房
|
|
|
- navigateToTuifang(){
|
|
|
|
|
- this.xuzhu_panduan=[]
|
|
|
|
|
|
|
+ navigateToTuifang(type){
|
|
|
|
|
+ this.tui_panduan=[]
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
|
this.getOrderPage()
|
|
this.getOrderPage()
|
|
|
},1)
|
|
},1)
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
|
- for (let i=0;i<this.xuzhu_type.length;i++){
|
|
|
|
|
- this.xuzhu_type.forEach(val => {
|
|
|
|
|
|
|
+ for (let i=0;i<this.tui_type.length;i++){
|
|
|
|
|
+ this.tui_type.forEach(val => {
|
|
|
if(val[i]==3) {
|
|
if(val[i]==3) {
|
|
|
- this.xuzhu_panduan.push(val)
|
|
|
|
|
|
|
+ this.tui_panduan.push(val)
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
|
- if(this.xuzhu_panduan.length>1) {
|
|
|
|
|
|
|
+ if(this.tui_panduan.length>=1) {
|
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
|
url:"../my_orderlist/my_orderlist?Inv=3"
|
|
url:"../my_orderlist/my_orderlist?Inv=3"
|
|
|
})
|
|
})
|
|
|
- }else if(this.xuzhu_panduan.length<1) {
|
|
|
|
|
|
|
+ }else if(this.tui_panduan.length<1) {
|
|
|
|
|
+ this.msgType = type
|
|
|
this.$refs.popup_tui.open()
|
|
this.$refs.popup_tui.open()
|
|
|
}
|
|
}
|
|
|
},150)
|
|
},150)
|
|
@@ -500,15 +533,20 @@
|
|
|
if(e.range.before!=''&&e.range.after=='') {
|
|
if(e.range.before!=''&&e.range.after=='') {
|
|
|
this.startWeek='周'+e.lunar.ncWeek.substring(2,3)
|
|
this.startWeek='周'+e.lunar.ncWeek.substring(2,3)
|
|
|
} else if(e.range.before!=''&&e.range.after!=''){
|
|
} else if(e.range.before!=''&&e.range.after!=''){
|
|
|
- this.endWeek='周'+e.lunar.ncWeek.substring(2,3)
|
|
|
|
|
- }
|
|
|
|
|
- this.startTime=e.range.before.substring(5,7)+'月'+e.range.before.substring(8,10)+'日'
|
|
|
|
|
- this.endTime=e.range.after.substring(5,7)+'月'+e.range.after.substring(8,10)+'日'
|
|
|
|
|
- this.startDate = e.range.before +' 14:00:00'
|
|
|
|
|
- this.endDate = e.range.after +' 12:00:00'
|
|
|
|
|
- this.ruzhu_num=parseInt(((new Date(e.range.after).getTime())-(new Date(e.range.before).getTime()))/1000/60/60/24)
|
|
|
|
|
- if(this.endDate !=' 12:00:00') {
|
|
|
|
|
- this.getRoomType()
|
|
|
|
|
|
|
+ if((new Date(e.range.after).getTime())<(new Date(e.range.before).getTime())) {
|
|
|
|
|
+ this.order_txt='离店日期不能小于到店日期'
|
|
|
|
|
+ this.$refs.popup_order.open()
|
|
|
|
|
+ }else{
|
|
|
|
|
+ this.endWeek='周'+e.lunar.ncWeek.substring(2,3)
|
|
|
|
|
+ this.startTime=e.range.before.substring(5,7)+'月'+e.range.before.substring(8,10)+'日'
|
|
|
|
|
+ this.endTime=e.range.after.substring(5,7)+'月'+e.range.after.substring(8,10)+'日'
|
|
|
|
|
+ this.startDate = e.range.before +' 14:00:00'
|
|
|
|
|
+ this.endDate = e.range.after +' 12:00:00'
|
|
|
|
|
+ this.ruzhu_num=parseInt(((new Date(e.range.after).getTime())-(new Date(e.range.before).getTime()))/1000/60/60/24)
|
|
|
|
|
+ if(this.endDate !=' 12:00:00') {
|
|
|
|
|
+ this.getRoomType()
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
},
|
|
},
|