Commit 72f18976 authored by 黄奎's avatar 黄奎

车修改

parent 55b84043
...@@ -166,7 +166,7 @@ ...@@ -166,7 +166,7 @@
</view> </view>
<view class="inputBoxRight"> <view class="inputBoxRight">
<input class="text-right" type="number" v-model="item.UserNum" <input class="text-right" type="number" v-model="item.UserNum"
@input="handleInput($event, item, 'UserNum')" @blur="handleBlur(item, 'UserNum')" /> @input="handleInput($event, item,1, 'UserNum')" @blur="handleBlur(item,1, 'UserNum')" />
</view> </view>
</view> </view>
<view class="inputBox row justify-between"> <view class="inputBox row justify-between">
...@@ -175,7 +175,7 @@ ...@@ -175,7 +175,7 @@
</view> </view>
<view class="inputBoxRight"> <view class="inputBoxRight">
<input class="text-right" type="number" v-model="item.UnitPrice" <input class="text-right" type="number" v-model="item.UnitPrice"
@input="handleInput($event, item, 'UnitPrice')" @blur="handleBlur(item, 'UnitPrice')" /> @input="handleInput($event, item,2, 'UnitPrice')" @blur="handleBlur(item,2, 'UnitPrice')" />
</view> </view>
</view> </view>
<view class="inputBox row justify-between noBorder"> <view class="inputBox row justify-between noBorder">
...@@ -249,7 +249,6 @@ ...@@ -249,7 +249,6 @@
watch: { watch: {
data: { data: {
handler(newVal, oldVal) { handler(newVal, oldVal) {
console.log("newVal", newVal);
if (oldVal.dataIndex1 != newVal.dataIndex1) { if (oldVal.dataIndex1 != newVal.dataIndex1) {
this.initData(); this.initData();
} else { } else {
...@@ -263,22 +262,39 @@ ...@@ -263,22 +262,39 @@
deep: true, deep: true,
immediate: false immediate: false
}, },
datas: {
handler(newVal, oldVal) {
this.updateData();
},
deep: true,
immediate: false
},
}, },
mounted() { mounted() {
this.initData(); this.initData();
}, },
methods: { methods: {
// 在模板中的使用示例 // 在模板中的使用示例
handleInput(e, item, field) { handleInput(e, item, type, field) {
const value = e.detail.value; const value = e.detail.value;
const validValue = this.$utils.checkInteger(value, true); var validValue = 0;
if (type == 1) {
validValue = this.$utils.checkInteger(value, true);
} else {
validValue = this.$utils.checkPrice(value, true);
}
// 更新数据 // 更新数据
item[field] = validValue; item[field] = validValue;
// 触发其他逻辑(如计算) // 触发其他逻辑(如计算)
this.getTotal(); this.getTotal();
}, },
handleBlur(item, field) { handleBlur(item, type, field) {
const formattedValue = this.$utils.checkPrice(item[field], true); var formattedValue = 0;
if (type == 1) {
formattedValue = this.$utils.checkInteger(item[field], true);
} else {
formattedValue = this.$utils.checkPrice(item[field], true);
}
// 更新数据 // 更新数据
item[field] = formattedValue; item[field] = formattedValue;
this.$set(item, field, formattedValue); this.$set(item, field, formattedValue);
...@@ -296,12 +312,10 @@ ...@@ -296,12 +312,10 @@
}, },
getTotal() { getTotal() {
let total = 0; let total = 0;
this.datas.ReimburseList.ReimburseDetailsList.forEach(x => { this.datas.ReimburseList.ReimburseDetailsList.forEach(x => {
total += x.UserNum * x.UnitPrice total += x.UserNum * x.UnitPrice
}) })
this.datas.TotalMoney = total this.datas.TotalMoney = total
this.updateData()
}, },
delInfor(index) { delInfor(index) {
this.datas.ReimburseList.ReimburseDetailsList.splice(index, 1) this.datas.ReimburseList.ReimburseDetailsList.splice(index, 1)
...@@ -312,7 +326,7 @@ ...@@ -312,7 +326,7 @@
}, },
getSettlementType(item) { getSettlementType(item) {
this.datas.ReimburseList.SettlementType = item.id this.datas.ReimburseList.SettlementType = item.id
this.updateData()
this.$forceUpdate() this.$forceUpdate()
}, },
updateData() { updateData() {
...@@ -342,7 +356,7 @@ ...@@ -342,7 +356,7 @@
let findIndex = this.optionList.findIndex(x => x.id == value) let findIndex = this.optionList.findIndex(x => x.id == value)
this.optionObj = this.optionList[findIndex] this.optionObj = this.optionList[findIndex]
this.datas.ReimburseList.ReimburseDetailsList[this.ReimIndex].UserTypeStr = this.optionObj.name this.datas.ReimburseList.ReimburseDetailsList[this.ReimIndex].UserTypeStr = this.optionObj.name
this.datas.ReimburseList.ReimburseDetailsList[this.ReimIndex].UserType = this.optionObj.id this.datas.ReimburseList.ReimburseDetailsList[this.ReimIndex].UserType = this.optionObj.id;
}, },
previewImage(src) { previewImage(src) {
uni.previewImage({ uni.previewImage({
......
<style lang="scss"> <style lang="scss">
@import url("@/asset/css/flex.css"); @import url("@/asset/css/flex.css");
.backBox{
width: 45rpx; .backBox {
height:45rpx; width: 45rpx;
background: rgba(23,23,23,.5); height: 45rpx;
border-radius: 50%; background: rgba(23, 23, 23, .5);
margin-top: 22rpx; border-radius: 50%;
} margin-top: 22rpx;
.backIcon{ }
display: inline-block;
margin-top: 6rpx; .backIcon {
} display: inline-block;
.backBox img{ margin-top: 6rpx;
width: 19rpx; }
height: 24rpx;
display: inline-block; .backBox img {
margin-top: 10rpx; width: 19rpx;
} height: 24rpx;
.itiner-title { display: inline-block;
line-height: 45px !important; margin-top: 10rpx;
font-size: 16px; }
position: fixed;
left: 0; .itiner-title {
top: 0; line-height: 45px !important;
width: 100%; font-size: 16px;
box-sizing: content-box; position: fixed;
z-index: 5; left: 0;
background-color: #0072FF; top: 0;
padding-left: 6rpx; width: 100%;
} box-sizing: content-box;
.itiner-titles{ z-index: 5;
color: #fff; background-color: #0072FF;
} padding-left: 6rpx;
.bjLine{ }
background: #F5F5F5;
height: 30rpx; .itiner-titles {
} color: #fff;
.itiner-c-title{ }
font-weight: bold;
} .bjLine {
.itiner-xincheng img{ background: #F5F5F5;
width: 31rpx; height: 30rpx;
height: 33rpx; }
}
.itiner-xincheng-left{ .itiner-c-title {
color: #838383; font-weight: bold;
} }
.itiner-xincheng-right view{
border: 1rpx solid #3581DA; .itiner-xincheng img {
color: #3581DA; width: 31rpx;
border-radius: 8rpx; height: 33rpx;
padding: 0 8rpx; }
}
.itiner-left-line{ .itiner-xincheng-left {
width: 9rpx; color: #838383;
height: 25rpx; }
border-radius: 100rpx;
background: #000; .itiner-xincheng-right view {
} border: 1rpx solid #3581DA;
.itiner-titleBox{ color: #3581DA;
border-bottom: 1px solid #eee; border-radius: 8rpx;
} padding: 0 8rpx;
.itiner-title-c{ }
padding: 25rpx 20rpx;
} .itiner-left-line {
.itiner-title-c.itiner-title-c-top{ width: 9rpx;
padding: 0rpx 20rpx; height: 25rpx;
} border-radius: 100rpx;
.itiner-title-c.active{ background: #000;
position: relative; }
color: #327FDE;
} .itiner-titleBox {
.itiner-title-c.active::after{ border-bottom: 1px solid #eee;
content: ''; }
position: absolute;
left: 0; .itiner-title-c {
bottom: 0; padding: 25rpx 20rpx;
width: 100%; }
height: 5rpx;
background: #3581DA; .itiner-title-c.itiner-title-c-top {
} padding: 0rpx 20rpx;
.itiner-feiyong{ }
background: #FF9702;
color: #fff; .itiner-title-c.active {
border-radius: 10rpx; position: relative;
padding: 0rpx 20rpx; color: #327FDE;
} }
.media{
position: relative; .itiner-title-c.active::after {
} content: '';
.detailsType{ position: absolute;
position: absolute; left: 0;
left: 20rpx; bottom: 0;
bottom: 10rpx; width: 100%;
background: #0130B0; height: 5rpx;
color: #fff; background: #3581DA;
border-radius: 25rpx; }
padding: 3rpx 20rpx 7rpx 20rpx;
z-index: 2; .itiner-feiyong {
} background: #FF9702;
.richText{ color: #fff;
// white-space: pre-wrap; border-radius: 10rpx;
} padding: 0rpx 20rpx;
.name-ali{ }
overflow: hidden;
white-space: nowrap; .media {
text-overflow: ellipsis; position: relative;
margin-right: 200rpx; }
}
.detailsType {
position: absolute;
left: 20rpx;
bottom: 10rpx;
background: #0130B0;
color: #fff;
border-radius: 25rpx;
padding: 3rpx 20rpx 7rpx 20rpx;
z-index: 2;
}
.richText {
// white-space: pre-wrap;
}
.name-ali {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
margin-right: 200rpx;
}
</style> </style>
<template> <template>
<scroll-view ref="scrollView" scroll-y="true" <scroll-view ref="scrollView" scroll-y="true" style="width: 100%; height: 100vh;" @scroll="scroll"
style="width: 100%; height: 100vh;" :scroll-top="scrollTop">
@scroll="scroll" <view class="media" :style="{ opacity: 100 - boxOption + '%' }" @click="openPicture">
:scroll-top="scrollTop"> <u-swiper :list="dataList.tempImgCover" :effect3d="false" :height="545" :interval="5000" :border-radius="0"
<view class="media" :style="{ opacity: 100 - boxOption + '%' }" name="Url" mode="number" indicatorPos="bottomRight">
@click="openPicture"> </u-swiper>
<u-swiper <view @click="goback" :style="[titleStyle, { opacity: '100% !important' }]"
:list="dataList.tempImgCover" style="position: fixed; top: 0; left: 0; padding-left: 6rpx">
:effect3d="false" <view class="backBox text-center">
:height="545" <u-icon class="backIcon" name="arrow-left" size="32" color="#FFF"></u-icon>
:interval="5000" </view>
:border-radius="0" </view>
name="Url" <!-- <view @click="goback" :style="[titleStyle, { opacity: '100% !important' }]"
mode="number"
indicatorPos="bottomRight">
</u-swiper>
<view @click="goback" :style="[titleStyle, { opacity: '100% !important' }]"
style="position: fixed; top: 0; left: 0; padding-left: 6rpx">
<view class="backBox text-center">
<u-icon class="backIcon" name="arrow-left" size="32" color="#FFF"></u-icon>
</view>
</view>
<!-- <view @click="goback" :style="[titleStyle, { opacity: '100% !important' }]"
style="position: fixed; top: 0; right: 200rpx; padding-right: 6rpx"> style="position: fixed; top: 0; right: 200rpx; padding-right: 6rpx">
<view class="backBox text-center"> <view class="backBox text-center">
<img src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638762515984923148.png" /> <img src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638762515984923148.png" />
</view> </view>
</view> --> </view> -->
<view class="detailsType fz24">{{ dataList.teamType==0?'跟团游':dataList.teamType==1?'小包团':'一日游' }}</view> <view class="detailsType fz24">{{ dataList.teamType==0?'跟团游':dataList.teamType==1?'小包团':'一日游' }}</view>
</view> </view>
<view class="itiner-title" :style="[titleStyle]"> <view class="itiner-title" :style="[titleStyle]">
<view class="itiner-titles row items-center text-center"> <view class="itiner-titles row items-center text-center">
<view @click="goback"> <view @click="goback">
<u-icon name="arrow-left" size="38"></u-icon> <u-icon name="arrow-left" size="38"></u-icon>
</view> </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">
{{ dataList.title?dataList.title:'' }} {{ dataList.title?dataList.title:'' }}
</view> </view>
</view> </view>
<view class="PX30 itiner-titleBox bgFFF row items-center justify-between"> <view class="PX30 itiner-titleBox bgFFF row items-center justify-between">
<view class="itiner-title-c itiner-title-c-top fz30" <view class="itiner-title-c itiner-title-c-top fz30" :class="[current==item.ID?'active':'']"
:class="[current==item.ID?'active':'']" v-for="(item,index) in titlesList" :key="index" @click="goTop(item)">
v-for="(item,index) in titlesList" {{ item.Name }}
:key="index" </view>
@click="goTop(item)"> </view>
{{ item.Name }} </view>
</view>
</view> <view class="itiner-content">
</view> <view class="PX30 PB20">
<view class="PT25 PB30 fz32 itiner-c-title">
<view class="itiner-content"> {{ dataList.title?dataList.title:'' }}
<view class="PX30 PB20"> </view>
<view class="PT25 PB30 fz32 itiner-c-title"> <view class="row justify-between items-center">
{{ dataList.title?dataList.title:'' }} <view class="row items-center">
</view> <!-- <view class="row items-center">
<view class="row justify-between items-center"> <view class="fz28 color9C9C9C">同业价:</view> <text
<view class="row items-center"> class="fontBold fz38 colorF99710">{{priceList&&priceList.length>0?priceList[0].b2BPrice:0}}</text><text
<view class="row items-center"><view class="fz28 color9C9C9C">同业价:</view> <text class="fontBold fz38 colorF99710">{{priceList&&priceList.length>0?priceList[0].b2BPrice:0}}</text><text class="fz24 ML10"> / 人</text></view> class="fz24 ML10"> / 人</text>
<view class="row items-center ML30"><view class="fz28 color9C9C9C">统一售价:</view> <text class="fontBold fz38 colorF99710">{{priceList&&priceList.length>0?priceList[0].b2CPrice:0}} </text><text class="fz24 ML10"> / 人</text></view> </view> -->
</view> <view class="row items-center ML30">
<!-- <view> <view class="fz28 color9C9C9C">统一售价:</view> <text
<u-icon class="backIcon" name="arrow-down" size="32" color="#9D9D9D"></u-icon> class="fontBold fz38 colorF99710">{{priceList&&priceList.length>0?priceList[0].b2CPrice:0}}
<u-icon class="backIcon" name="arrow-up" size="32" color="#9D9D9D"></u-icon> </text><text class="fz24 ML10"> / 人</text>
</view> --> </view>
</view>
<!-- <view class="colorE1432E fz28 PT10">
op备注:
</view> -->
</view>
<view class="bjLine"></view>
<view class="PX30 PB20">
<view class="MT15 itiner-xincheng row items-center">
<img src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638875112655075900.png"/>
<view class="itiner-xincheng-left ML30 MR30 fz26">行程天数</view>
<view class="itiner-xincheng-right fz28 row items-center"> {{ dataList.dayNum>=0?dataList.dayNum:'' }}<text class="ML10 MR10"></text>
{{ dataList.nightNum>=0?dataList.nightNum:'' }} <tetx class="ML10 MR10"></tetx>
{{ dataList.teamType==0?'跟团游':dataList.teamType==1?'小包团':'一日游' }}
<view class="ML30 MR10" @click="downloadTripPlanHandler">行程下载</view></view>
</view>
<view class="MT10 itiner-xincheng row items-center">
<img src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638875112698474332.png"/>
<view class="itiner-xincheng-left ML30 MR30 fz26">出发城市</view>
<view class="itiner-xincheng-right fz28 row items-center">{{ dataList.startCityName?dataList.startCityName:'' }}</view>
</view>
</view>
<view class="bjLine"></view>
<view class="PX30">
<view class="PY20 row justify-between items-center" @click="showQinDan=!showQinDan">
<view class="row items-center">
<view class="itiner-left-line">&nbsp;</view>
<text class="fz32 fontBold ML20">报名清单</text>
</view>
<view>
<u-icon class="backIcon" :name="!showQinDan?'arrow-down':'arrow-up'" size="32" color="#9D9D9D"></u-icon>
</view>
</view>
<view class="" v-if="showQinDan">
<view class="fz28">
<view>本团机位</view>
<template v-if="priceList&&priceList.length>0">
<view v-if="priceList[0].cSeat>0">头等舱: {{ priceList[0].cSeat }}</view>
<view v-if="priceList[0].fSeat>0">商务舱: {{ priceList[0].fSeat }}</view>
<view v-if="priceList[0].ySeat>0">经济舱: {{ priceList[0].ySeat }}</view>
</template>
</view>
<view class="fz28 PT15 PB20">报名人数:
<template v-if="priceList&&priceList.length>0">{{ priceList[0].offerFSeat+priceList[0].offerCSeat+priceList[0].offerYSeat }}</template>
</view> </view>
</view> </view>
</view> </view>
<view class="bjLine"></view> <view class="bjLine"></view>
<view class="PX30"> <view class="PX30 PB20">
<view class="PY20 row justify-between items-center" @click="showMaiDian=!showMaiDian"> <view class="MT15 itiner-xincheng row items-center">
<view class="row items-center"> <img
<view class="itiner-left-line">&nbsp;</view> src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638875112655075900.png" />
<text class="fz32 fontBold ML20">本团卖点</text> <view class="itiner-xincheng-left ML30 MR30 fz26">行程天数</view>
</view> <view class="itiner-xincheng-right fz28 row items-center">
<view> {{ dataList.dayNum>=0?dataList.dayNum:'' }}<text class="ML10 MR10"></text>
<u-icon class="backIcon" :name="!showMaiDian?'arrow-down':'arrow-up'" size="32" color="#9D9D9D"></u-icon> {{ dataList.nightNum>=0?dataList.nightNum:'' }}
</view> <tetx class="ML10 MR10"></tetx>
</view> {{ dataList.teamType==0?'跟团游':dataList.teamType==1?'小包团':'一日游' }}
<view v-if="showMaiDian" class=""> <view class="ML30 MR10" @click="downloadTripPlanHandler">行程下载</view>
<view v-if="dataList.productRecommend" class="fz28 PB20"> </view>
<rich-text :nodes="dataList.productRecommend" class="richText"></rich-text> </view>
</view> <view class="MT10 itiner-xincheng row items-center">
<view v-else class="fz28 PB20" style="color: #7B7B7B;">暂无填写</view> <img
</view> src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638875112698474332.png" />
</view> <view class="itiner-xincheng-left ML30 MR30 fz26">出发城市</view>
<view class="bjLine"></view> <view class="itiner-xincheng-right fz28 row items-center">
<view class="PX30"> {{ dataList.startCityName?dataList.startCityName:'' }}</view>
<view class="PY20 row justify-between items-center" @click="showHangBan=!showHangBan"> </view>
<view class="row items-center"> </view>
<view class="itiner-left-line">&nbsp;</view> <view class="bjLine"></view>
<text class="fz32 fontBold ML20">航班信息</text> <view class="PX30">
</view> <view class="PY20 row justify-between items-center" @click="showQinDan=!showQinDan">
<view> <view class="row items-center">
<u-icon class="backIcon" :name="!showHangBan?'arrow-down':'arrow-up'" size="32" color="#9D9D9D"></u-icon> <view class="itiner-left-line">&nbsp;</view>
</view> <text class="fz32 fontBold ML20">报名清单</text>
</view> </view>
<view v-if="showHangBan" class=""> <view>
<template v-if="priceList.length>0"> <u-icon class="backIcon" :name="!showQinDan?'arrow-down':'arrow-up'" size="32"
<view class="fz28 PB20"> color="#9D9D9D"></u-icon>
<view class="priceFlightTitle row color000"> </view>
<view class="flex1">航班号</view> </view>
<view class="flex1">起飞时间</view> <view class="" v-if="showQinDan">
<view class="flex1">到达时间</view> <view class="fz28">
</view> <view>本团机位</view>
<view class="priceFlightText fz28 row color666 MT20" v-for="(item,index) in priceList[0].priceFlight"> <template v-if="priceList&&priceList.length>0">
<view class="flex1"> <view v-if="priceList[0].cSeat>0">头等舱: {{ priceList[0].cSeat }}</view>
<view class="fz24"> {{ item.flightNumber }}</view> <view v-if="priceList[0].fSeat>0">商务舱: {{ priceList[0].fSeat }}</view>
{{ item.alName }} <view v-if="priceList[0].ySeat>0">经济舱: {{ priceList[0].ySeat }}</view>
</view> </template>
<view class="flex1"> </view>
<view class="fz24"> {{ item.startDate }} {{ item.departureTime }}</view> <view class="fz28 PT15 PB20">报名人数:
{{ item.departureAirPortName }} <template
<view v-if="item.stopoverAirPortName" class="fz24"> v-if="priceList&&priceList.length>0">{{ priceList[0].offerFSeat+priceList[0].offerCSeat+priceList[0].offerYSeat }}</template>
中:{{ item.stopoverAirPortName }} </view>
</view> </view>
</view> </view>
<view class="flex1"> <view class="bjLine"></view>
<view class="fz24"> {{ item.arriveDate }} {{ item.arrivalTime }}</view> <view class="PX30">
{{ item.arrivalAirPortName }} <view class="PY20 row justify-between items-center" @click="showMaiDian=!showMaiDian">
</view> <view class="row items-center">
</view> <view class="itiner-left-line">&nbsp;</view>
</view> <text class="fz32 fontBold ML20">本团卖点</text>
</template> </view>
<view v-else class="fz28 PB20" style="color: #7B7B7B;">暂无航班信息</view> <view>
</view> <u-icon class="backIcon" :name="!showMaiDian?'arrow-down':'arrow-up'" size="32"
</view> color="#9D9D9D"></u-icon>
<view class="bjLine"></view> </view>
<view class="PX30 itiner-titleBox row items-center justify-between"> </view>
<view class="itiner-title-c fz30" <view v-if="showMaiDian" class="">
:class="[current==item.ID?'active':'']" <view v-if="dataList.productRecommend" class="fz28 PB20">
v-for="(item,index) in titlesList" <rich-text :nodes="dataList.productRecommend" class="richText"></rich-text>
:key="index" </view>
@click="goTop(item)"> <view v-else class="fz28 PB20" style="color: #7B7B7B;">暂无填写</view>
{{ item.Name }} </view>
</view> </view>
</view> <view class="bjLine"></view>
<view style="line-height: 50rpx;"> <view class="PX30">
<view class="PX30" id="title1"> <view class="PY20 row justify-between items-center" @click="showHangBan=!showHangBan">
<view class="PY20 row items-center"> <view class="row items-center">
<view class="itiner-left-line">&nbsp;</view> <view class="itiner-left-line">&nbsp;</view>
<text class="fz32 fontBold ML20">行程特色</text> <text class="fz32 fontBold ML20">航班信息</text>
</view> </view>
<view v-if="dataList.feature&&dataList.feature.tripImageList&&dataList.feature.tripImageList.length>0"> <view>
<image v-for="x in dataList.feature.tripImageList" :src="x" mode="widthFix" <u-icon class="backIcon" :name="!showHangBan?'arrow-down':'arrow-up'" size="32"
@click='previewTravelPicHandler(x,dataList.feature.tripImageList)' color="#9D9D9D"></u-icon>
style="width: 100%"> </view>
</image> </view>
</view> <view v-if="showHangBan" class="">
</view> <template v-if="priceList.length>0">
<view class="PX30" id="title2"> <view class="fz28 PB20">
<view class="PY20 row items-center"> <view class="priceFlightTitle row color000">
<view class="itiner-left-line">&nbsp;</view> <view class="flex1">航班号</view>
<text class="fz32 fontBold ML20">行程介绍</text> <view class="flex1">起飞时间</view>
</view> <view class="flex1">到达时间</view>
<view> </view>
<view v-if="d.length>0&&dataList.feature&&dataList.feature.detailsImageList.length==0"> <view class="priceFlightText fz28 row color666 MT20"
<view v-for="(x,i) in d" :key="i" class="column PB20"> v-for="(item,index) in priceList[0].priceFlight">
<view class="column fz32 fontBold PB20"> <view class="flex1">
<text>第{{(i+1)>9?(i+1):'0'+(i+1)}}天</text> <view class="fz24"> {{ item.flightNumber }}</view>
<text class="fz28 MT20" style="font-family: microsoft yahei ui light;"> {{ item.alName }}
{{x.title}} </view>
</text> <view class="flex1">
</view> <view class="fz24"> {{ item.startDate }} {{ item.departureTime }}</view>
{{ item.departureAirPortName }}
<template v-for="(y,yi) in x.dayArray"> <view v-if="item.stopoverAirPortName" class="fz24">
<view v-if="y.childItem&&y.childItem.imaArray&&y.childItem.imaArray.length>0&&y.type==2" 中:{{ item.stopoverAirPortName }}
class="MB20" </view>
style="border: 1px solid #ddd;"> </view>
<view v-for="(z,zi) in y.childItem.imaArray"> <view class="flex1">
<image <view class="fz24"> {{ item.arriveDate }} {{ item.arrivalTime }}</view>
@click="previewImages(y.childItem.imaArray,zi)" {{ item.arrivalAirPortName }}
:src="z.url" mode="aspectFill" </view>
:key="zi" style="width: 100%;" </view>
v-if="y.type==2"></image> </view>
</view> </template>
<view :key="yi" v-if="y.type==2" class="PA20"> <view v-else class="fz28 PB20" style="color: #7B7B7B;">暂无航班信息</view>
<view class="fz30 fontBold PB20">{{`${y.childItem.couponsName}`}}</view> </view>
<view class="fz28 color666"> </view>
<rich-text :nodes="y.childItem.description" class="richText"></rich-text> <view class="bjLine"></view>
</view> <view class="PX30 itiner-titleBox row items-center justify-between">
</view> <view class="itiner-title-c fz30" :class="[current==item.ID?'active':'']"
</view> v-for="(item,index) in titlesList" :key="index" @click="goTop(item)">
<view :key="yi" v-if="y.type==6"> {{ item.Name }}
<view class="fz30 fontWeight500 PY20 colorE1432E">温馨提示</view> </view>
<view class="fz28 PB20 color666"> </view>
<rich-text :nodes="y.childItem.description" class="richText"></rich-text> <view style="line-height: 50rpx;">
</view> <view class="PX30" id="title1">
</view> <view class="PY20 row items-center">
</template> <view class="itiner-left-line">&nbsp;</view>
<view class="row" v-if="x.canshi"> <text class="fz32 fontBold ML20">行程特色</text>
<view> </view>
<image style="width: 45rpx;height: 45rpx;display: block;" <view
mode="aspectFill" v-if="dataList.feature&&dataList.feature.tripImageList&&dataList.feature.tripImageList.length>0">
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638876765053973357.png"/> <image v-for="x in dataList.feature.tripImageList" :src="x" mode="widthFix"
</view> @click='previewTravelPicHandler(x,dataList.feature.tripImageList)' style="width: 100%">
<view class="PL20"> </image>
<view class="row PB20" v-for="item in x.canshi"> </view>
<view class="fz34 fontBold MR20 flexS"> </view>
{{`${item.childItem.timeStr} ${item.childItem.dinnerTypeName}`}} <view class="PX30" id="title2">
</view> <view class="PY20 row items-center">
<view class="fz28 MR20 color666">{{item.childItem.dinnerName?item.childItem.dinnerName:'方便游玩敬请自理'}}</view> <view class="itiner-left-line">&nbsp;</view>
</view> <text class="fz32 fontBold ML20">行程介绍</text>
</view> </view>
</view> <view>
<view class="row" v-if="x.zhusu"> <view v-if="d.length>0&&dataList.feature&&dataList.feature.detailsImageList.length==0">
<view> <view v-for="(x,i) in d" :key="i" class="column PB20">
<image style="width: 45rpx;height: 45rpx;display: block;" <view class="column fz32 fontBold PB20">
mode="aspectFill" <text>第{{(i+1)>9?(i+1):'0'+(i+1)}}天</text>
src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638876765089861843.png"/> <text class="fz28 MT20" style="font-family: microsoft yahei ui light;">
</view> {{x.title}}
<view class="PL20"> </text>
<view class="row" v-for="item in x.zhusu"> </view>
<view class="fz34 fontBold MR20 flexS">
住宿
</view>
<view class="fz28 MR20 color666">{{item.childItem.hotelName}}</view>
</view>
</view>
</view>
</view>
</view>
<view class="PB20 bgFFF" v-if="dataList.feature&&dataList.feature.detailsImageList.length>0">
<image class="MB20" :src="x" @click='previewTravelPicHandler(x,dataList.feature.detailsImageList)'
mode="widthFix" style="width: 100%;height: auto;"
v-for="x in dataList.feature.detailsImageList"></image>
</view>
</view>
</view>
<view class="PX30" id="title3">
<view class="PY20 row items-center">
<view class="itiner-left-line">&nbsp;</view>
<text class="fz32 fontBold ML20">费用说明</text>
</view>
<view class="PB20">
<text class="itiner-feiyong">费用包含</text>
</view>
<view class="PB20">
<view class="fz26 color666">
<rich-text :nodes="dataList.feature.feeInclude?dataList.feature.feeInclude:'暂无'" class="richText"></rich-text>
</view>
</view>
<view class="PB20">
<text class="itiner-feiyong">费用不含</text>
</view>
<view class="PB20">
<view class="fz26 color666">
<rich-text :nodes="dataList.feature.feeNonInclude?dataList.feature.feeNonInclude:'暂无'" class="richText"></rich-text>
</view> <template v-for="(y,yi) in x.dayArray">
</view> <view
</view> v-if="y.childItem&&y.childItem.imaArray&&y.childItem.imaArray.length>0&&y.type==2"
<view class="PX30" id="title4"> class="MB20" style="border: 1px solid #ddd;">
<view class="PY20 row items-center"> <view v-for="(z,zi) in y.childItem.imaArray">
<view class="itiner-left-line">&nbsp;</view> <image @click="previewImages(y.childItem.imaArray,zi)" :src="z.url"
<text class="fz32 fontBold ML20">预定须知</text> mode="aspectFill" :key="zi" style="width: 100%;" v-if="y.type==2">
</view> </image>
<view class="PB20"> </view>
<text class="itiner-win colorE1432E fontBold">重要提示</text> <view :key="yi" v-if="y.type==2" class="PA20">
</view> <view class="fz30 fontBold PB20">{{`${y.childItem.couponsName}`}}</view>
<view class="PB20"> <view class="fz28 color666">
<view class="fz26"> <rich-text :nodes="y.childItem.description"
<rich-text :nodes="dataList.feature.importantTipText?dataList.feature.importantTipText:'暂无'" class="richText"></rich-text> class="richText"></rich-text>
</view> </view>
</view> </view>
<view class="PB20"> </view>
<text class="itiner-tisp colorF99710 fontBold">温馨提示</text> <view :key="yi" v-if="y.type==6">
</view> <view class="fz30 fontWeight500 PY20 colorE1432E">温馨提示</view>
<view class="PB20"> <view class="fz28 PB20 color666">
<view class="fz26"> <rich-text :nodes="y.childItem.description" class="richText"></rich-text>
<rich-text :nodes="dataList.feature.warmTip?dataList.feature.warmTip:'暂无'" class="richText"></rich-text> </view>
</view> </view>
</view> </template>
<template v-if="dataList.feature.b2BRemarkText"> <view class="row" v-if="x.canshi">
<view class="PB20"> <view>
<text class="itiner-tisp colorF99710 fontBold">同行备注</text> <image style="width: 45rpx;height: 45rpx;display: block;" mode="aspectFill"
</view> src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638876765053973357.png" />
<view class="PB20"> </view>
<view class="fz26"> <view class="PL20">
<rich-text :nodes="dataList.feature.b2BRemarkText?dataList.feature.b2BRemarkText:'暂无'" class="richText"></rich-text> <view class="row PB20" v-for="item in x.canshi">
</view> <view class="fz34 fontBold MR20 flexS">
</view> {{`${item.childItem.timeStr} ${item.childItem.dinnerTypeName}`}}
</template> </view>
<template v-if="dataList.feature.shopRemarkText"> <view class="fz28 MR20 color666">
<view class="PB20"> {{item.childItem.dinnerName?item.childItem.dinnerName:'方便游玩敬请自理'}}
<text class="itiner-tisp colorF99710 fontBold">购物店</text> </view>
</view> </view>
<view class="PB20"> </view>
<view class="fz26"> </view>
<rich-text :nodes="dataList.feature.shopRemarkText?dataList.feature.shopRemarkText:'暂无'" class="richText"></rich-text> <view class="row" v-if="x.zhusu">
</view> <view>
</view> <image style="width: 45rpx;height: 45rpx;display: block;" mode="aspectFill"
</template> src="https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638876765089861843.png" />
</view> </view>
</view> <view class="PL20">
</view> <view class="row" v-for="item in x.zhusu">
</scroll-view> <view class="fz34 fontBold MR20 flexS">
住宿
</view>
<view class="fz28 MR20 color666">{{item.childItem.hotelName}}</view>
</view>
</view>
</view>
</view>
</view>
<view class="PB20 bgFFF" v-if="dataList.feature&&dataList.feature.detailsImageList.length>0">
<image class="MB20" :src="x"
@click='previewTravelPicHandler(x,dataList.feature.detailsImageList)' mode="widthFix"
style="width: 100%;height: auto;" v-for="x in dataList.feature.detailsImageList">
</image>
</view>
</view>
</view>
<view class="PX30" id="title3">
<view class="PY20 row items-center">
<view class="itiner-left-line">&nbsp;</view>
<text class="fz32 fontBold ML20">费用说明</text>
</view>
<view class="PB20">
<text class="itiner-feiyong">费用包含</text>
</view>
<view class="PB20">
<view class="fz26 color666">
<rich-text :nodes="dataList.feature.feeInclude?dataList.feature.feeInclude:'暂无'"
class="richText"></rich-text>
</view>
</view>
<view class="PB20">
<text class="itiner-feiyong">费用不含</text>
</view>
<view class="PB20">
<view class="fz26 color666">
<rich-text :nodes="dataList.feature.feeNonInclude?dataList.feature.feeNonInclude:'暂无'"
class="richText"></rich-text>
</view>
</view>
</view>
<view class="PX30" id="title4">
<view class="PY20 row items-center">
<view class="itiner-left-line">&nbsp;</view>
<text class="fz32 fontBold ML20">预定须知</text>
</view>
<view class="PB20">
<text class="itiner-win colorE1432E fontBold">重要提示</text>
</view>
<view class="PB20">
<view class="fz26">
<rich-text :nodes="dataList.feature.importantTipText?dataList.feature.importantTipText:'暂无'"
class="richText"></rich-text>
</view>
</view>
<view class="PB20">
<text class="itiner-tisp colorF99710 fontBold">温馨提示</text>
</view>
<view class="PB20">
<view class="fz26">
<rich-text :nodes="dataList.feature.warmTip?dataList.feature.warmTip:'暂无'"
class="richText"></rich-text>
</view>
</view>
<template v-if="dataList.feature.b2BRemarkText">
<view class="PB20">
<text class="itiner-tisp colorF99710 fontBold">同行备注</text>
</view>
<view class="PB20">
<view class="fz26">
<rich-text :nodes="dataList.feature.b2BRemarkText?dataList.feature.b2BRemarkText:'暂无'"
class="richText"></rich-text>
</view>
</view>
</template>
<template v-if="dataList.feature.shopRemarkText">
<view class="PB20">
<text class="itiner-tisp colorF99710 fontBold">购物店</text>
</view>
<view class="PB20">
<view class="fz26">
<rich-text :nodes="dataList.feature.shopRemarkText?dataList.feature.shopRemarkText:'暂无'"
class="richText"></rich-text>
</view>
</view>
</template>
</view>
</view>
</view>
</scroll-view>
</template> </template>
<script> <script>
export default { export default {
data() { data() {
return { return {
scrollTop: 0, scrollTop: 0,
old: { old: {
scrollTop: 0 scrollTop: 0
}, },
boxOption: 0, boxOption: 0,
titleStyle: { titleStyle: {
opacity: 0, opacity: 0,
}, },
imgsList: [ imgsList: [{
{ url: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png',
url: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png', Path: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png',
Path: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png', },
}, {
{ url: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png',
url: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png', Path: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png',
Path: 'https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Upload/Goods/638874829612454395.png', },
}, ],
], titlesList: [{
titlesList:[{ Name: '行程特色',
Name: '行程特色', ID: 1,
ID: 1, val: 'title1',
val: 'title1', top: 0,
top: 0, },
}, {
{ Name: '行程',
Name: '行程', ID: 2,
ID: 2, val: 'title2',
val: 'title2', top: 0,
top: 0, },
}, {
{ Name: '费用说明',
Name: '费用说明', ID: 3,
ID: 3, val: 'title3',
val: 'title3', top: 0,
top: 0, },
}, {
{ Name: '预定须知',
Name: '预定须知', ID: 4,
ID: 4, val: 'title4',
val: 'title4', top: 0,
top: 0, },
}, ],
], current: 1,
current: 1, msg: {
msg: { configId: '',
configId: '', cityId: '',
cityId: '', tcid: '',
tcid: '', },
}, dataList: {},
dataList: {}, priceList: [],
priceList: [], isDownloading: false,
isDownloading: false, showQinDan: false,
showQinDan: false, showMaiDian: false,
showMaiDian: false, showHangBan: false,
showHangBan: false, d: [],
d: [], Up: {},
Up: {}, }
} },
}, computed: {
computed: {
}, },
created() { created() {
}, },
onLoad(options) { onLoad(options) {
if(options.configId){ if (options.configId) {
this.msg.configId = options.configId this.msg.configId = options.configId
this.init() this.init()
} }
if(options.TCID){ if (options.TCID) {
this.msg.tcid = options.TCID this.msg.tcid = options.TCID
} }
this.Up = uni.getStorageSync("mall_UserInfo") ? this.Up = uni.getStorageSync("mall_UserInfo") ?
uni.getStorageSync("mall_UserInfo").UserPageType : uni.getStorageSync("mall_UserInfo").UserPageType :
0; 0;
}, },
onShow() { onShow() {
let that = this; let that = this;
uni.getSystemInfo({ uni.getSystemInfo({
success(res) { success(res) {
that.titleStyle = { that.titleStyle = {
height: "45px", height: "45px",
paddingTop: `${res.statusBarHeight}px`, paddingTop: `${res.statusBarHeight}px`,
opacity: "0", opacity: "0",
}; };
}, },
}); });
}, },
watch: { watch: {
d:{ d: {
handler(newVal,oldVal){ handler(newVal, oldVal) {
if(this.d&&this.d.length > 0){ if (this.d && this.d.length > 0) {
setTimeout(()=>{ setTimeout(() => {
this.titlesList.forEach((x,index) => { this.titlesList.forEach((x, index) => {
if(index==1) x.Name = `${this.dataList.dayNum}日行程` if (index == 1) x.Name = `${this.dataList.dayNum}日行程`
const query = uni.createSelectorQuery().select(`#${x.val}`); const query = uni.createSelectorQuery().select(`#${x.val}`);
if(query) query.boundingClientRect((rect) => { if (query) query.boundingClientRect((rect) => {
x.top = rect.top-130; x.top = rect.top - 130;
}).exec(); }).exec();
if(index==3) uni.hideLoading() if (index == 3) uni.hideLoading()
}) })
},10000) }, 10000)
} }
}, },
deep:true, deep: true,
immediate:false immediate: false
}, },
}, },
mounted() { mounted() {
},
methods: {
goTop(item) {
this.current = item.ID;
this.$nextTick(function() {
this.scrollTop = item.top
});
},
async formatDay() {
this.d = this.dataList.dayList
if (this.d.length > 0) {
await this.d.forEach((x) => {
x.dayArray.forEach((y) => {
if (y.type == 7) {
x.title = y.childItem.title;
} else if (y.type == 1) {
y.subtitle =
y.childItem.subTraffic.length > 0 && y.childItem.subTraffic[0]
.startTime +
" - " +
y.childItem.subTraffic[y.childItem.subTraffic.length - 1]
.endTime;
y.title = this.formatTraffice(y.childItem.subTraffic);
y.icon = "iconfont iconjiaotong";
} else if (y.type == 4) {
let t = ["早餐", "午餐", "晚餐"];
y.childItem.dinnerTypeName =
t[parseInt(y.childItem.useDinnerType) - 1];
}
});
x.dayArray = x.dayArray.sort((a, b) => {
return new Date(a.type) - new Date(b.type)
})
x.zhusu = x.dayArray.filter(z => z.type == 3)
x.canshi = x.dayArray.filter(z => z.type == 4)
});
}
},
formatTraffice(tras) {
let txt = "从" + (tras.length > 0 ? tras[0].startCityName : '');
tras.forEach((z, i) => {
if (i > 0 && txt != '') {
txt += ";再";
}
if (z.arrivalType == 1) {
txt += "搭乘航班";
} else if (z.arrivalType == 2) {
txt += "乘坐豪华巴士";
} else if (z.arrivalType == 3) {
txt += "乘坐豪华游轮";
} else {
txt += "乘坐高铁";
}
txt += " 到达" + z.arrivalCityName;
});
return txt;
},
init() {
uni.showLoading({
title: '加载中...',
})
this.apipost("b2b_get_GetB2BTravelInfoNoDes", this.msg, (res) => {
if (res.resultCode == 1) {
res.data.tempImgCover = JSON.parse(res.data.imgCover);
this.dataList = res.data
this.priceList = res.data.priceList
this.formatDay()
}
}, (failed) => {
uni.hideLoading()
uni.showToast({
title: failed.message,
icon: "none",
});
}, (error) => {
uni.hideLoading()
})
},
goback() {
uni.navigateBack({
delta: 1,
});
},
previewImages(images, cur) {
let imgObj = [];
if (images[0].url) {
imgObj = []
images.forEach(x => imgObj.push(x.url))
}
uni.previewImage({
urls: imgObj,
current: cur,
})
},
previewTravelPicHandler(url, urls) {
uni.previewImage({
urls: urls,
current: url,
})
},
openPicture() {
let imgObj = JSON.stringify(this.dataList.tempImgCover);
uni.navigateTo({
url: "/pages/hotel/picture?imgObj=" + imgObj + "&isLine=1",
});
},
scroll(e) {
this.old.scrollTop = e.detail.scrollTop
this.boxOption = Math.floor((e.detail.scrollTop - 650) / 1.5);
this.titleStyle.opacity =
e.detail.scrollTop - 650 < 0 ?
0 :
Math.floor(e.detail.scrollTop - 650) / 100 > 1 ?
1 :
Math.floor(e.detail.scrollTop - 650) / 100;
this.titlesList.forEach((x, index) => {
let pev
let nex
pev = this.titlesList[index - 1]
nex = this.titlesList[index + 1]
if (this.old.scrollTop > x.top && nex != undefined && this.old.scrollTop < nex.top) {
this.current = nex.ID
} else if (this.old.scrollTop > x.top && nex == undefined) {
this.current = 4
} else if (this.old.scrollTop < x.top && pev != undefined && this.old.scrollTop > pev.top) {
this.current = pev.ID
} else if (this.old.scrollTop < x.top && pev == undefined) {
this.current = 1
}
})
this.$forceUpdate();
},
downloadTripPlanHandler() {
if (this.isDownloading) return;
let that = this
uni.showLoading({
title: '这可能需要30秒,请耐心等待'
})
this.isDownloading = true
let url =
`https://im.oytour.com/TripDownLoad/${this.msg.configId}_${this.msg.tcid}/${this.msg.configId}_${this.msg.tcid}.pdf`
}, let fileName =
methods: { `${this.dataList.ltName.replace(/\s+/g,"").replaceAll("/","")}`
goTop(item) {
this.current = item.ID;
this.$nextTick(function() {
this.scrollTop = item.top
});
},
async formatDay() {
this.d = this.dataList.dayList
if (this.d.length > 0) {
await this.d.forEach((x) => {
x.dayArray.forEach((y) => {
if (y.type == 7) {
x.title = y.childItem.title;
} else if (y.type == 1) {
y.subtitle =
y.childItem.subTraffic.length > 0 && y.childItem.subTraffic[0]
.startTime +
" - " +
y.childItem.subTraffic[y.childItem.subTraffic.length - 1]
.endTime;
y.title = this.formatTraffice(y.childItem.subTraffic);
y.icon = "iconfont iconjiaotong";
} else if (y.type == 4) {
let t = ["早餐", "午餐", "晚餐"];
y.childItem.dinnerTypeName =
t[parseInt(y.childItem.useDinnerType) - 1];
}
});
x.dayArray = x.dayArray.sort((a,b)=>{
return new Date(a.type) - new Date(b.type)
})
x.zhusu = x.dayArray.filter(z=>z.type==3)
x.canshi = x.dayArray.filter(z=>z.type==4)
});
}
},
formatTraffice(tras) {
let txt = "从" + (tras.length > 0 ? tras[0].startCityName : '');
tras.forEach((z, i) => {
if (i > 0 && txt != '') {
txt += ";再";
}
if (z.arrivalType == 1) {
txt += "搭乘航班";
} else if (z.arrivalType == 2) {
txt += "乘坐豪华巴士";
} else if (z.arrivalType == 3) {
txt += "乘坐豪华游轮";
} else {
txt += "乘坐高铁";
}
txt += " 到达" + z.arrivalCityName;
});
return txt;
},
init(){
uni.showLoading({
title: '加载中...',
})
this.apipost("b2b_get_GetB2BTravelInfoNoDes", this.msg, (res) => {
if (res.resultCode == 1) {
res.data.tempImgCover = JSON.parse(res.data.imgCover);
this.dataList = res.data
this.priceList = res.data.priceList
this.formatDay()
}
}, (failed) => {
uni.hideLoading()
uni.showToast({
title: failed.message,
icon: "none",
});
}, (error) => {
uni.hideLoading()
})
},
goback() {
uni.navigateBack({
delta: 1,
});
},
previewImages(images, cur) {
let imgObj = [];
if (images[0].url) {
imgObj = []
images.forEach(x => imgObj.push(x.url))
}
uni.previewImage({
urls: imgObj,
current: cur,
})
},
previewTravelPicHandler(url, urls) {
uni.previewImage({
urls: urls,
current: url,
})
},
openPicture() {
let imgObj = JSON.stringify(this.dataList.tempImgCover);
uni.navigateTo({
url: "/pages/hotel/picture?imgObj=" + imgObj+"&isLine=1",
});
},
scroll(e) {
this.old.scrollTop = e.detail.scrollTop
this.boxOption = Math.floor((e.detail.scrollTop - 650) / 1.5);
this.titleStyle.opacity =
e.detail.scrollTop - 650 < 0 ?
0 :
Math.floor(e.detail.scrollTop - 650) / 100 > 1 ?
1 :
Math.floor(e.detail.scrollTop - 650) / 100;
this.titlesList.forEach((x,index)=>{
let pev
let nex
pev = this.titlesList[index-1]
nex = this.titlesList[index+1]
if(this.old.scrollTop>x.top&&nex!=undefined&&this.old.scrollTop<nex.top){
this.current = nex.ID
}else if(this.old.scrollTop>x.top&&nex==undefined){
this.current = 4
} else if(this.old.scrollTop<x.top&&pev!=undefined&&this.old.scrollTop>pev.top){
this.current = pev.ID
}else if(this.old.scrollTop<x.top&&pev==undefined){
this.current = 1
}
})
this.$forceUpdate();
},
downloadTripPlanHandler() {
if (this.isDownloading) return;
let that = this
uni.showLoading({
title: '这可能需要30秒,请耐心等待'
})
this.isDownloading = true
let url =
`https://im.oytour.com/TripDownLoad/${this.msg.configId}_${this.msg.tcid}/${this.msg.configId}_${this.msg.tcid}.pdf`
let fileName = const filePath = wx.env.USER_DATA_PATH + `/${fileName}.pdf`
`${this.dataList.ltName.replace(/\s+/g,"").replaceAll("/","")}` uni.downloadFile({
url: url,
const filePath = wx.env.USER_DATA_PATH + `/${fileName}.pdf` filePath,
uni.downloadFile({ success: (res) => {
url: url, wx.openDocument({
filePath, filePath: filePath,
success: (res) => { showMenu: true,
wx.openDocument({ success: fres => {
filePath: filePath, uni.hideLoading()
showMenu: true, that.isDownloading = false
success: fres => { },
uni.hideLoading() fail: fres => {
that.isDownloading = false console.log('downloadTripPlanHandler_打开失败', fres)
}, that.downloadFailed('打开失败,请重试。如果仍然失败,请联系销售索要PDF行程')
fail: fres => { },
console.log('downloadTripPlanHandler_打开失败', fres) })
that.downloadFailed('打开失败,请重试。如果仍然失败,请联系销售索要PDF行程') },
}, fail(err) {
}) console.log("downloadTripPlanHandler_fail", err)
}, that.downloadFailed('下载失败,请重试。如果仍然失败,请联系销售索要PDF行程' + err)
fail(err) { },
console.log("downloadTripPlanHandler_fail", err) });
that.downloadFailed('下载失败,请重试。如果仍然失败,请联系销售索要PDF行程' + err) },
}, downloadFailed(msg) {
}); uni.showToast({
}, icon: 'none',
downloadFailed(msg) { title: msg
uni.showToast({ })
icon: 'none', this.isDownloading = false;
title: msg },
}) // #ifdef MP-WEIXIN
this.isDownloading = false;
},
// #ifdef MP-WEIXIN
//分享朋友圈 //分享朋友圈
onShareTimeline() { onShareTimeline() {
let uid = uni.getStorageSync("mall_UserInfo") ? let uid = uni.getStorageSync("mall_UserInfo") ?
...@@ -778,7 +800,7 @@ export default { ...@@ -778,7 +800,7 @@ export default {
"&configId=" + "&configId=" +
this.msg.configId + this.msg.configId +
"&cityId=" + "&cityId=" +
this.msg.cityId+this.$uiConfig.DIRECT_PARAMETER, this.msg.cityId + this.$uiConfig.DIRECT_PARAMETER,
imageUrl: imageUrl, imageUrl: imageUrl,
}; };
}, },
...@@ -809,7 +831,7 @@ export default { ...@@ -809,7 +831,7 @@ export default {
"&configId=" + "&configId=" +
this.msg.configId + this.msg.configId +
"&cityId=" + "&cityId=" +
this.msg.cityId+this.$uiConfig.DIRECT_PARAMETER, this.msg.cityId + this.$uiConfig.DIRECT_PARAMETER,
imageUrl: "", imageUrl: "",
// imageUrl: // imageUrl:
// this.dataList.tempImgCover && this.dataList.tempImgCover.length > 0 // this.dataList.tempImgCover && this.dataList.tempImgCover.length > 0
...@@ -817,6 +839,6 @@ export default { ...@@ -817,6 +839,6 @@ export default {
// : "", // : "",
}; };
}, },
}, },
} }
</script> </script>
\ No newline at end of file
...@@ -542,8 +542,8 @@ ...@@ -542,8 +542,8 @@
title: '保存中...' title: '保存中...'
}) })
this.apipost("dmcstatistics_post_SetNewLeaderApplyList_V2", this.params, (res) => { this.apipost("dmcstatistics_post_SetNewLeaderApplyList_V2", this.params, (res) => {
this.loading = false;
if (res.resultCode == 1) { if (res.resultCode == 1) {
this.loading = false
uni.showToast({ uni.showToast({
title: '操作成功!', title: '操作成功!',
icon: 'success', icon: 'success',
......
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