Commit 61d9e618 authored by youjie's avatar youjie

Merge branch 'B2C' of http://gitlab.oytour.com/zk123/jz_travel into B2C

parents fa5386df 397d38e7
......@@ -209,12 +209,12 @@
let msg = null
// #ifdef MP-DI
console.log(item.goodsType,'===========')
console.log(item.goodsType, '===========')
msg = `OrderNo=${item.orderNo}`
if (item.goodsType > 0 && item.goodsType < 4) url = `jiuzhai/jz_SureOrder?` //线路
else if (item.goodsType > 3 && item.goodsType < 8) { //景点门票
} else if (item.goodsType > 7 && item.goodsType < 12) { //酒店住宿
url = `hotel/orderdetails?`
url = `hotel/orderdetails?orderId=` + item.erpOrderId;
} else if (item.goodsType > 11 && item.goodsType < 15) { //目的地用车
} else if (item.goodsType == 15) url = `visa/visa_SureOrder?` //签证
else if (item.goodsType == 16) url = `airTicket/airTicketOrderDetail?` //机票
......@@ -225,9 +225,8 @@
else if (item.goodsType == 4) { //景点门票
} else if (item.goodsType == 3) { //酒店住宿
} else if (item.goodsType == 7) { //酒店住宿
url = `hotel/orderdetails?`
} else if (item.goodsType == 9) { //酒店住宿
url = `hotel/orderdetails?orderId=` + item.erpOrderId;
} else if (item.goodsType == 5) { //目的地用车
} else if (item.goodsType == 6) url = `visa/visa_SureOrder?` //签证
else if (item.goodsType == 1) { //机票
......
......@@ -487,7 +487,7 @@
icon: 'none',
title: '订单创建成功'
})
this.goPayHandler(res.data.OrderNo);
this.goPayHandler(res.data);
} else {
uni.showToast({
title: res.message,
......@@ -498,7 +498,8 @@
}
});
},
goPayHandler(OrderNo) {
goPayHandler(item) {
let OrderNo=item.OrderNo;
let that = this;
uni.requestPayment({
provider: "wxpay",
......@@ -529,7 +530,7 @@
});
setTimeout(() => {
uni.redirectTo({
url: "/pages/hotel/orderdetails?OrderNo=" + OrderNo,
url: "/pages/hotel/orderdetails?orderId=" + item.ErpOrderId,
});
}, 100);
},
......
<template>
<view class="hotel-detail" v-if="orderData">
<scroll-view
ref="scrollView"
scroll-y="true"
style="height: 1px;flex: 1;box-sizing: border-box;"
@scroll="scroll"
>
<view
class="media"
:style="{ opacity: 100 - boxOption + '%' }"
>
<scroll-view ref="scrollView" scroll-y="true" style="height: 1px;flex: 1;box-sizing: border-box;"
@scroll="scroll">
<view class="media" :style="{ opacity: 100 - boxOption + '%' }">
<!-- #ifdef MP-WEIXIN -->
<view
@click="goback"
:style="[titleStyle, { opacity: '100% !important' }]"
style="position: fixed; top: 0; left: 0; padding-left: 6rpx"
>
<u-icon
name="arrow-left"
size="44"
style="margin-top: 22rpx"
></u-icon>
<view @click="goback" :style="[titleStyle, { opacity: '100% !important' }]"
style="position: fixed; top: 0; left: 0; padding-left: 6rpx">
<u-icon name="arrow-left" size="44" style="margin-top: 22rpx"></u-icon>
</view>
<!-- #endif -->
<view class="orderStatusBox flex" style="margin-bottom: 30rpx">
<u-icon customPrefix="iconfont" name="icondaizhifu-" size="52" color="#DFBE6E" v-if="orderStatus.code == 0"></u-icon>
<u-icon customPrefix="iconfont" name="iconquxiao" size="52" color="#f26c6c" v-if="orderStatus.code == -1"></u-icon>
<u-icon customPrefix="iconfont" name="iconshenhezhong" size="52" color="#86d9a5" v-if="orderStatus.code == -2"></u-icon>
<u-icon customPrefix="iconfont" name="iconzhengchang" size="52" color="#111" v-if="orderStatus.code == 1"></u-icon>
<u-icon customPrefix="iconfont" name="icondaizhifu-" size="52" color="#DFBE6E"
v-if="orderStatus.code == 0"></u-icon>
<u-icon customPrefix="iconfont" name="iconquxiao" size="52" color="#f26c6c"
v-if="orderStatus.code == -1"></u-icon>
<u-icon customPrefix="iconfont" name="iconshenhezhong" size="52" color="#86d9a5"
v-if="orderStatus.code == -2"></u-icon>
<u-icon customPrefix="iconfont" name="iconzhengchang" size="52" color="#111"
v-if="orderStatus.code == 1"></u-icon>
<text style="
margin-left: 26rpx;
font-size: 40rpx;
......@@ -40,23 +30,25 @@
</view>
<view class="orderIforRzBox row">
<view class="orderIforRzImg">
<img
style="width: 14rpx;height: 68rpx;"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638766174213789755.png"/>
<img style="width: 14rpx;height: 68rpx;"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638766174213789755.png" />
</view>
<view class="orderIforRzTime column col">
<view>入住:<text>{{getDate(orderData.parmResultRoomInfo.CheckInDate)}} {{ getWeek(orderData.parmResultRoomInfo.CheckInDate) }} 14:00后</text></view>
<view style="margin-top: 28rpx;">离店:<text>{{getDate(orderData.parmResultRoomInfo.CheckOutDate)}} {{ getWeek(orderData.parmResultRoomInfo.CheckOutDate) }} 12:00前</text></view>
<view>入住:<text>{{getDate(orderData.parmResultRoomInfo.CheckInDate)}}
{{ getWeek(orderData.parmResultRoomInfo.CheckInDate) }} 14:00后</text></view>
<view style="margin-top: 28rpx;">离店:<text>{{getDate(orderData.parmResultRoomInfo.CheckOutDate)}}
{{ getWeek(orderData.parmResultRoomInfo.CheckOutDate) }} 12:00前</text></view>
</view>
<view class="orderIforRzNum">
{{getDay(orderData.parmResultRoomInfo.CheckInDate.slice(0, 10),orderData.parmResultRoomInfo.CheckOutDate.slice(0, 10))}}
</view>
<view class="orderIforRzNum">{{getDay(orderData.parmResultRoomInfo.CheckInDate.slice(0, 10),orderData.parmResultRoomInfo.CheckOutDate.slice(0, 10))}}</view>
</view>
<view class="orderIforDiZhi">
<view class="orderIforDiZhiL">{{ orderData.parmResultRoomInfo.HotelName }}</view>
<view class="orderIforDiZhiR row">
<view class="orderIforDiZhiRImg">
<img
style="width: 23rpx;height:28rpx;"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638766148323678002.png"/>
<img style="width: 23rpx;height:28rpx;"
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638766148323678002.png" />
</view>
<view class="orderIforDiZhiRText">
酒店地址
......@@ -70,13 +62,9 @@
<u-icon name="arrow-left" size="44"></u-icon>
<!-- #endif -->
</view>
<view
style="flex: 1; margin-left: 30rpx; text-align: left"
class="name-ali"
>
<view style="flex: 1; margin-left: 30rpx; text-align: left" class="name-ali">
{{ orderData.parmResultRoomInfo.HotelName }}
</view
>
</view>
</view>
<view class="ReservationInforBox">
<view class="ReservationInforTitle">预定信息</view>
......@@ -93,7 +81,7 @@
<view class="ResInforL">餐型</view>
<view class="ResInforR active">
<view v-if="RatePlanList && RatePlanList.length > 0">
<template v-for="( itemp, indexp ) in RatePlanList[0].PriceList" >
<template v-for="( itemp, indexp ) in RatePlanList[0].PriceList">
<template v-if="!indexp">
{{getMealtype(itemp.MealType)}}
<template v-if="itemp.MealAmount>0">
......@@ -104,26 +92,6 @@
</view>
</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL">窗户</view>
<view class="ResInforR">窗户</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL">人数</view>
<view class="ResInforR">最多入住人数</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL">面积</view>
<view class="ResInforR">面积㎡</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL">网络</view>
<view class="ResInforR">是否有WIFI</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL">楼层数</view>
<view class="ResInforR">楼层数</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL">取消政策</view>
<view class="ResInforR">
......@@ -161,7 +129,8 @@
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL Lwidth">联系姓名</view>
<view class="ResInforR">{{ orderData.parmResultRoomInfo.SurName }}{{ orderData.parmResultRoomInfo.Name }}</view>
<view class="ResInforR">
{{ orderData.parmResultRoomInfo.SurName }}{{ orderData.parmResultRoomInfo.Name }}</view>
</view>
<view class="ResInforText row-sb-n">
<view class="ResInforL Lwidth">联系电话</view>
......@@ -193,8 +162,7 @@
<view class="label"> 明细 </view>
</view>
<view class="flex f12 grey" style="margin-bottom: 40rpx"
v-for="(item,index) in orderData.parmResultRoomInfo.GuestList"
:key="index">
v-for="(item,index) in orderData.parmResultRoomInfo.GuestList" :key="index">
<view style="flex: 1">
<text style="margin-right: 30rpx">房间数</text>
</view>
......@@ -203,8 +171,7 @@
</view>
</view>
<view class="flex f12 grey" style="margin-bottom: 40rpx"
:style="{'color':mainColor+' !important'}"
<view class="flex f12 grey" style="margin-bottom: 40rpx" :style="{'color':mainColor+' !important'}"
v-if="orderData.model.DiscountMoney&&orderData.model.DiscountMoney>0">
<view style="flex: 1">
<text style="margin-right: 30rpx">优惠金额</text>
......@@ -239,23 +206,19 @@
<view class="jz_orderbox flex" v-if="showPayBtn">
<view style="display: flex">
<!-- #ifdef MP-DI -->
<button v-if="orderData.model.OrderStatus==1"
class="jz_OrderReNow" @click="goCancel"
style="background: #fff; color: #111; border: 1px solid #111"
:disabled="submitCancel"
<button v-if="orderData.model.OrderStatus==1" class="jz_OrderReNow" @click="goCancel"
style="background: #fff; color: #111; border: 1px solid #111" :disabled="submitCancel"
:loading="submitCancel">
取消
</button>
<button v-if="orderData.model.OrderStatus==1" class="jz_OrderReNow"
style="margin-left: 20rpx;"
<button v-if="orderData.model.OrderStatus==1" class="jz_OrderReNow" style="margin-left: 20rpx;"
@click="submitGetCodeByOrderNo" :disabled="submit" :loading="submit">
立即支付
</button>
<!-- #endif -->
<!-- #ifdef MP-AG -->
<button v-if="orderData.model.OrderStatus==1" class="jz_OrderReNow" @click="goCancel"
style="background: #fff; color: #111; border: 1px solid #111"
:disabled="submitCancel"
style="background: #fff; color: #111; border: 1px solid #111" :disabled="submitCancel"
:loading="submitCancel">
取消
</button>
......@@ -263,9 +226,9 @@
</view>
</view>
</view>
</template>
</template>
<script>
<script>
import cancelProgress from '@/components/cancelPrompt/cancelProgress.vue'
export default {
components: {
......@@ -283,7 +246,7 @@
Up: 0,
current: 1,
scrollTop: 100,
old:{
old: {
scrollTop: 0
},
orderStatus: {
......@@ -292,14 +255,14 @@
},
showPayBtn: false,
btnStyle: {
height:"80rpx",
lineHeight:"80rpx",
borderRadius:"16rpx",
background:"#111",
color:"#FFF",
fontSize:"28rpx",
fontWeight:"600",
width:'193rpx',
height: "80rpx",
lineHeight: "80rpx",
borderRadius: "16rpx",
background: "#111",
color: "#FFF",
fontSize: "28rpx",
fontWeight: "600",
width: '193rpx',
},
orderData: null,
orderStatus: {
......@@ -319,11 +282,12 @@
};
},
created() {
this.Up = uni.getStorageSync("mall_UserInfo")
? uni.getStorageSync("mall_UserInfo").UserPageType
: 0;
this.Up = uni.getStorageSync("mall_UserInfo") ?
uni.getStorageSync("mall_UserInfo").UserPageType :
0;
},
onLoad(options) {
console.log("options", options);
this.id = options.orderId;
let that = this;
uni.getSystemInfo({
......@@ -336,7 +300,7 @@
},
});
this.mainColor = this.$uiConfig.mainColor;
if(this.id) this.getOrderDetail(this.id);
if (this.id) this.getOrderDetail(this.id);
this.getdidaMealType()
},
methods: {
......@@ -348,27 +312,27 @@
MallBaseId: uni.getStorageSync("mall_UserInfo").MallBaseId
}, (res) => {
if (res.resultCode == 1) {
this.orderInfo =JSON.parse(res.data.sPayInfo)
this.orderInfo = JSON.parse(res.data.sPayInfo)
this.goPayHandler();
} else {
uni.showToast({
title:res.message,
icon:'none',
duration:3000
title: res.message,
icon: 'none',
duration: 3000
})
this.submit = false;
}
},e=>{
}, e => {
uni.showToast({
title:'无法发起支付,请稍后',
icon:'none',
duration:3000
title: '无法发起支付,请稍后',
icon: 'none',
duration: 3000
})
this.submit=false
this.submit = false
});
},
goCancel() {
if(this.submitCancel) return
if (this.submitCancel) return
this.submitCancel = true
this.apipost(
"dmc_post_GetDiDaBookingCancel", {
......@@ -394,7 +358,7 @@
);
},
//立即购买
buyRoom(){
buyRoom() {
let that = this;
if (that.orderMsg.Consignee == '') {
this.$refs.uToast.show({
......@@ -412,9 +376,9 @@
}
var tempObj = uni.getStorageSync('basedata').mall.wechatmessage;
var tmplIds = [];
if(tempObj&&tempObj.length>0){
tempObj.forEach(x=>{
if(x.Name=='下单成功提醒'||x.Name=='订单取消提醒'||x.Name=='订单确认通知'){
if (tempObj && tempObj.length > 0) {
tempObj.forEach(x => {
if (x.Name == '下单成功提醒' || x.Name == '订单取消提醒' || x.Name == '订单确认通知') {
tmplIds.push(x.MessageId)
}
})
......@@ -449,11 +413,11 @@
this.orderStatus.code = 0;
this.orderStatus.text = "已完成";
this.showPayBtn = false;
}else if (status == 2) {
} else if (status == 2) {
this.orderStatus.code = 1;
this.orderStatus.text = "正常";
this.showPayBtn = false;
}else if (status == 5) {
} else if (status == 5) {
this.orderStatus.code = 0;
this.orderStatus.text = "售后";
this.showPayBtn = false;
......@@ -472,7 +436,7 @@
this.orderStatus.code = 0;
this.orderStatus.text = "已完成";
this.showPayBtn = false;
}else if (status == 2) {
} else if (status == 2) {
this.orderStatus.code = 1;
this.orderStatus.text = "正常";
this.showPayBtn = false;
......@@ -483,11 +447,11 @@
this.old.scrollTop = e.detail.scrollTop
this.boxOption = Math.floor((e.detail.scrollTop - 50) / 1.5);
this.titleStyle.opacity =
e.detail.scrollTop - 100 < 0
? 0
: Math.floor(e.detail.scrollTop - 100) / 100 > 1
? 1
: Math.floor(e.detail.scrollTop - 100) / 100;
e.detail.scrollTop - 100 < 0 ?
0 :
Math.floor(e.detail.scrollTop - 100) / 100 > 1 ?
1 :
Math.floor(e.detail.scrollTop - 100) / 100;
this.$forceUpdate();
},
goback() {
......@@ -525,7 +489,7 @@
this.formatStatus(res.data.model.OrderStatus);
console.log(res, '订单详情数据');
}
},err=>{
}, err => {
uni.hideLoading();
}
);
......@@ -581,10 +545,11 @@
},
},
};
</script>
</script>
<style scoped>
<style scoped>
@import url("@/asset/css/flex.css");
.hotel-detail {
height: 100vh;
overflow: hidden;
......@@ -711,17 +676,21 @@
line-height: 43rpx;
text-indent: 21rpx;
}
.hotel-detail .hotel-content .title-style-one item-title{
.hotel-detail .hotel-content .title-style-one item-title {
line-height: 36rpx;
}
.hotel-detail .hotel-content .title-style-one .item-content{
.hotel-detail .hotel-content .title-style-one .item-content {
color: #B99846;
margin-left: 5rpx;
line-height: 36rpx;
}
.title-style-one li{
.title-style-one li {
margin-bottom: 5rpx;
}
.hotel-detail .hotel-content .big-title {
position: relative;
font-size: 32rpx;
......@@ -778,12 +747,7 @@
color: #ffffff;
}
.hotel-detail
.hotel-content
.hotel-base
.hotel-room
.room-type
.item:last-child {
.hotel-detail .hotel-content .hotel-base .hotel-room .room-type .item:last-child {
margin-right: 0;
}
......@@ -848,7 +812,8 @@
font-weight: 500;
color: #6e6e6e;
}
.hotel-Opening{
.hotel-Opening {
font-weight: 500;
font-size: 24rpx;
color: #B99846;
......@@ -856,7 +821,8 @@
margin-bottom: 20rpx;
display: inline-block;
}
.hotel-tagText{
.hotel-tagText {
background: #FFFFFF;
border-radius: 4rpx;
border: 1rpx solid #B99846;
......@@ -869,6 +835,7 @@
padding: 0 12rpx;
display: inline-block;
}
.hotel-detail .hotel-content .hotel-base .head .op-box image {
width: 58rpx;
height: 58rpx;
......@@ -931,7 +898,7 @@
position: relative;
z-index: 1;
background: #fff;
box-shadow: 0rpx 14rpx 40rpx 0rpx rgba(76,76,76,0.06);
box-shadow: 0rpx 14rpx 40rpx 0rpx rgba(76, 76, 76, 0.06);
border-radius: 0rpx 0rpx 40rpx 40rpx;
overflow: hidden;
}
......@@ -1022,6 +989,7 @@
.hotel-detail .media .media-info .mi-left {
flex: 1;
}
.detail_ShareBtn {
width: 100%;
height: 100%;
......@@ -1030,6 +998,7 @@
top: 0;
opacity: 0;
}
.name-ali {
/* #ifdef MP-ALIPAY */
box-sizing: border-box;
......@@ -1037,20 +1006,23 @@
/* #endif */
}
.orderIforDiZhi{
.orderIforDiZhi {
padding: 27rpx 32rpx 41rpx 32rpx;
}
.orderIforDiZhiL{
.orderIforDiZhiL {
font-weight: 800;
font-size: 32rpx;
color: #080A09;
padding-bottom: 18rpx;
}
.orderIforDiZhiRImg{
.orderIforDiZhiRImg {
width: 23rpx;
margin-right: 13rpx;
}
.orderIforDiZhiRText{
.orderIforDiZhiRText {
width: 1px;
flex: 1;
font-weight: 500;
......@@ -1058,22 +1030,26 @@
color: #1D1D20;
line-height: 38rpx;
}
.ReservationInforBox{
.ReservationInforBox {
border-radius: 18rpx;
background: #fff;
margin: 28rpx 31rpx 28rpx 31rpx;
padding: 37rpx 18rpx 49rpx 18rpx;
}
.ReservationInforTitle{
.ReservationInforTitle {
font-weight: 800;
font-size: 32rpx;
color: #080A09;
padding-bottom: 24rpx;
}
.ResInforText{
.ResInforText {
padding: 21rpx 19rpx;
}
.ResInforL{
.ResInforL {
width: 120rpx;
text-align: right;
margin-right: 57rpx;
......@@ -1081,56 +1057,66 @@
font-size: 28rpx;
color: #303133;
}
.ResInforL.Lwidth{
.ResInforL.Lwidth {
width: 130rpx;
}
.ResInforR{
.ResInforR {
width: 1px;
flex: 1;
font-weight: bold;
font-size: 28rpx;
color: #080A09;
}
.ResInforR.active{
.ResInforR.active {
color: #B99846;
}
.ResInforTisp{
.ResInforTisp {
font-weight: 500;
font-size: 24rpx;
color: #1D1D20;
line-height: 42rpx;
}
.ResInforText.ResInforTtisp{
.ResInforText.ResInforTtisp {
padding: 14rpx 19rpx 21rpx 19rpx;
}
.orderStatusBox{
.orderStatusBox {
padding: 200rpx 31rpx 13rpx 31rpx;
}
.orderIforRzBox{
.orderIforRzBox {
margin: 0 31rpx;
background: #ECF1F4;
border-radius: 18rpx;
align-items: center;
padding: 31rpx 38rpx;
}
.orderIforRzTime{
.orderIforRzTime {
font-weight: 500;
font-size: 28rpx;
color: #1D1D20;
margin-left: 16rpx;
}
.orderIforRzNum{
.orderIforRzNum {
font-weight: bold;
font-size: 32rpx;
color: #080A09;
}
.opera-box{
.opera-box {
background-color: #FFF;
padding: 20rpx 45rpx 40rpx 45rpx;
z-index: 5;
}
.opera-box .box{
.opera-box .box {
height: 100rpx;
background: #FFFFFF;
box-shadow: 0px 10rpx 30rpx 0px rgba(36, 36, 36, 0.2);
......@@ -1139,13 +1125,15 @@
align-items: center;
padding: 0 10rpx 0 36rpx;
}
.opera-box .box .price{
.opera-box .box .price {
font-size: 40rpx;
font-weight: 500;
color: #D91818;
margin-right: 20rpx;
}
.opera-box .box .sum-detail{
.opera-box .box .sum-detail {
font-size: 24rpx;
flex: 1;
font-weight: 500;
......@@ -1165,8 +1153,9 @@
z-index: 99;
justify-content: flex-end;
padding: 20rpx 30rpx;
}
.jz_OrderDiv {
}
.jz_OrderDiv {
width: 90%;
height: 100rpx;
background-color: #fff;
......@@ -1178,9 +1167,9 @@
box-shadow: 0px 10rpx 30rpx 0px rgba(36, 36, 36, 0.2);
border-radius: 16px;
z-index: 999;
}
}
.jz_OrderReNow {
.jz_OrderReNow {
width: 170rpx;
height: 80rpx;
background-color: #111111;
......@@ -1190,33 +1179,38 @@
font-weight: 600;
font-size: 28rpx;
border-radius: 16rpx;
}
.big-title{
}
.big-title {
font-size: 32rpx;
color: #080A09;
padding-bottom: 24rpx;
font-weight: 800;
}
.regular {
font-weight: 500 ;
}
.label {
}
.regular {
font-weight: 500;
}
.label {
font-size: 28rpx;
font-weight: 600;
margin-right: 60rpx;
flex-shrink: 0;
}
.grey {
}
.grey {
color: #6e6e6e;
}
.f12 {
font-size: 24rpx ;
}
.form-items:first-child{
}
.f12 {
font-size: 24rpx;
}
.form-items:first-child {
padding: 0 0 30rpx 0;
display: flex;
border-bottom: 1px solid #e6e6e6;
}
</style>
\ No newline at end of file
}
</style>
\ No newline at end of file
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