Commit 968dc344 authored by youjie's avatar youjie

修复bug

parent 7fa9c614
...@@ -301,16 +301,18 @@ ...@@ -301,16 +301,18 @@
</div> </div>
<q-separator /> <q-separator />
<div class="flex"> <div class="flex">
<div class="category-item" :key="i" v-for="(x, i) in categoryList"> <div class="category-item" :key="i" v-for="(x, i) in categoryList"
@click="x.SubList&&x.SubList.length>0&&x.CategoryName!='行程线路'?'':productSearch(x)"
:class="[x.SubList&&x.SubList.length>0&&x.CategoryName!='行程线路'?'':'cursor-pointer']">
<div :key="i" v-for="item in x.SubList"> <div :key="i" v-for="item in x.SubList">
<div @click="x.CategoryName=='行程线路'?OpenNewUrl(item.LinkUrl):handleCategoryChage(item)" <div @click.stop="x.CategoryName=='行程线路'?OpenNewUrl(item.LinkUrl):handleCategoryChage(item)"
class="category-l2" :class="{ class="category-l2" :class="{
'category-l2-select': selectCategory === item.Id, 'category-l2-select': selectCategory === item.Id,
}"> }">
{{ item.CategoryName }} {{ item.CategoryName }}
</div> </div>
<div v-if="item.SubList&&item.SubList.length"> <div v-if="item.SubList&&item.SubList.length">
<div @click="x.CategoryName=='行程线路'?OpenNewUrl(item2.LinkUrl):handleCategoryChage(item2)" <div @click.stop="x.CategoryName=='行程线路'?OpenNewUrl(item2.LinkUrl):handleCategoryChage(item2)"
class="category-l3" :class="{ class="category-l3" :class="{
'category-l3-select': selectCategory === item2.Id, 'category-l3-select': selectCategory === item2.Id,
}" :key="index" v-for="(item2,index) in item.SubList"> }" :key="index" v-for="(item2,index) in item.SubList">
...@@ -527,8 +529,9 @@ ...@@ -527,8 +529,9 @@
}, 300) }, 300)
}, },
productSearch(item){ productSearch(item){
if(item.CategoryName=='机票') this.handleCategoryChage(item)//this.handleCategoryChage(item,2) if(item.CategoryName=='机票') this.handleCategoryChage(item,0)//this.handleCategoryChage(item,2)
if(item.CategoryName=='签证') this.handleCategoryChage(item,3) else if(item.CategoryName=='签证') this.handleCategoryChage(item,3)
else this.handleCategoryChage(item,0)
}, },
mouseenterAddress() { mouseenterAddress() {
this.menuFocusAll = 0; this.menuFocusAll = 0;
......
...@@ -777,6 +777,9 @@ export default { ...@@ -777,6 +777,9 @@ export default {
tempArray.forEach(item => { tempArray.forEach(item => {
if (item.coverImageList && item.coverImageList.length>0) { if (item.coverImageList && item.coverImageList.length>0) {
try { try {
item.coverImageList = item.coverImageList.filter(item=>{
return item.url!=null
})
var imgArray = item.coverImageList; var imgArray = item.coverImageList;
if (imgArray && imgArray.length > 0) { if (imgArray && imgArray.length > 0) {
item.newCoverImg = imgArray[0].url; item.newCoverImg = imgArray[0].url;
......
...@@ -64,38 +64,38 @@ ...@@ -64,38 +64,38 @@
/> />
</div> </div>
<div class="q-py-lg"> <div class="q-py-lg">
<div class="row" v-if="dataList.TypeTagList"> <div class="row q-pb-xs" v-if="dataList.TypeTagList&&dataList.TypeTagList.length>0">
<span class="col-2 text-dark">签证类型</span> <span class="col-2 text-dark">签证类型</span>
<span class="col text-grey-7" v-for="(x,index) in dataList.TypeTagList"> <span class="col text-grey-7" v-for="(x,index) in dataList.TypeTagList">
{{ x.TagTame }} {{ x.TagTame }}
<template v-if="dataList.TypeTagList.length-1!=index">; </template> <template v-if="dataList.TypeTagList.length-1!=index">; </template>
</span> </span>
</div> </div>
<div class="row q-pt-xs" v-if="dataList.ManageDuration"> <div class="row q-pb-xs" v-if="dataList.ManageDuration">
<span class="col-2 text-dark">办理时长</span> <span class="col-2 text-dark">办理时长</span>
<span class="col text-grey-7"> <span class="col text-grey-7">
收齐资料后需{{ dataList.ManageDuration }}个工作日 收齐资料后需{{ dataList.ManageDuration }}个工作日
</span> </span>
</div> </div>
<div class="row q-pt-xs" v-if="dataList.EntryType"> <div class="row q-pb-xs" v-if="dataList.EntryType">
<span class="col-2 text-dark">入境次数</span> <span class="col-2 text-dark">入境次数</span>
<span class="col text-grey-7"> <span class="col text-grey-7">
{{ dataList.EntryType==1?'单次':dataList.EntryType==2?'多次':'' }} {{ dataList.EntryType==1?'单次':dataList.EntryType==2?'多次':'' }}
</span> </span>
</div> </div>
<div class="row q-pt-xs" v-if="dataList.StayDays"> <div class="row q-pb-xs" v-if="dataList.StayDays">
<span class="col-2 text-dark">可停留天数</span> <span class="col-2 text-dark">可停留天数</span>
<span class="col text-grey-7"> <span class="col text-grey-7">
{{ dataList.StayDays }} {{ dataList.StayDays }}
</span> </span>
</div> </div>
<div class="row q-pt-xs" v-if="dataList.VisaValidity"> <div class="row q-pb-xs" v-if="dataList.VisaValidity">
<span class="col-2 text-dark">签证有效期</span> <span class="col-2 text-dark">签证有效期</span>
<span class="col text-grey-7"> <span class="col text-grey-7">
{{ dataList.VisaValidity }} {{ dataList.VisaValidity }}
</span> </span>
</div> </div>
<!-- <div class="row q-pt-lg" v-if="dataList.VisaProductInfo&&dataList.VisaProductInfo.AcceptRange"> <!-- <div class="row q-pb-lg" v-if="dataList.VisaProductInfo&&dataList.VisaProductInfo.AcceptRange">
<span class="col-2 text-dark">受理范围</span> <span class="col-2 text-dark">受理范围</span>
<div class="col text-grey-7"> <div class="col text-grey-7">
<span class="col"> <span class="col">
...@@ -259,17 +259,23 @@ ...@@ -259,17 +259,23 @@
<div class="q-mt-md trip-text" v-html="dataList.VisaProductInfo.VisaMaterials" :class="{ <div class="q-mt-md trip-text" v-html="dataList.VisaProductInfo.VisaMaterials" :class="{
'q-px-md': $q.screen.width < 1220 && $q.platform.is.mobile, 'q-px-md': $q.screen.width < 1220 && $q.platform.is.mobile,
}"></div> }"></div>
<div v-if="dataList.DownloadName" class="q-mt-md trip-text row justify-end" :class="{ <template v-if="dataList.VisaProductInfo&&dataList.VisaProductInfo.DownloadMaterialsFileList.length>0">
'q-px-md': $q.screen.width < 1220 && $q.platform.is.mobile, <template v-for="(item,index) in dataList.VisaProductInfo.DownloadMaterialsFileList" >
}"> <div v-if="item.Url"
<span class="text-red-6">{{ dataList.DownloadName }}</span> class="q-mt-md trip-text row justify-end" :class="{
<q-chip 'q-px-md': $q.screen.width < 1220 && $q.platform.is.mobile,
style="background: #26a69a1a" }" @click="downloadHandler(item)">
size="sm" <span class="text-red-6 col">{{ item.Name}}</span>
class="f12 rounded-borders text-secondary q-ml-lg cursor-pointer" <q-chip
label="下载" @click="downloadHandler" style="background: #26a69a1a"
/> size="sm"
</div> class="f12 rounded-borders text-secondary q-ml-lg cursor-pointer"
label="下载"
/>
</div>
</template>
</template>
<div class="text-h5 text-weight-bold text-left q-mt-xl" ref="tips" :class="{ <div class="text-h5 text-weight-bold text-left q-mt-xl" ref="tips" :class="{
...@@ -514,8 +520,15 @@ ...@@ -514,8 +520,15 @@
localStorage.setItem("lineVisas",JSON.stringify(lineVisas)) localStorage.setItem("lineVisas",JSON.stringify(lineVisas))
this.CommonJump('/visaOrderPriview/'+key, {}); this.CommonJump('/visaOrderPriview/'+key, {});
}, },
downloadHandler(){ async downloadHandler(item){
window.open(this.dataList.VisaProductInfo.DownloadMaterials) let response = await fetch(item.Url);
let blob = await response.blob();
let objectUrl = window.URL.createObjectURL(blob);
let a = document.createElement('a');
a.href = objectUrl;
a.download = item.Name; // 设置下载文件的名字
a.click();
a.remove();
}, },
getTripFeatureImageHandler(configId) { getTripFeatureImageHandler(configId) {
this.$axios this.$axios
...@@ -706,10 +719,9 @@ ...@@ -706,10 +719,9 @@
this.tripImages = []; this.tripImages = [];
this.detailsImageList = []; this.detailsImageList = [];
this.dataList = r.data.data; this.dataList = r.data.data;
let arr = this.dataList.VisaProductInfo.DownloadMaterials.split('/') this.dataList.CoverImageList = this.dataList.CoverImageList.filter(item=>{
if(arr.length > 0){ return item.Url!=null
this.dataList.DownloadName = arr[arr.length - 1] })
}
if (this.dataList.dayList && this.dataList.dayList.length > 0) { if (this.dataList.dayList && this.dataList.dayList.length > 0) {
this.dataList.dayList.forEach((item) => { this.dataList.dayList.forEach((item) => {
item.slide = 0; item.slide = 0;
......
...@@ -125,12 +125,19 @@ ...@@ -125,12 +125,19 @@
<q-card flat class="q-pa-md q-my-lg"> <q-card flat class="q-pa-md q-my-lg">
<div class="text-subtitle1 text-weight-bolder q-mb-md">客户資料</div> <div class="text-subtitle1 text-weight-bolder q-mb-md">客户資料</div>
<div class="row"> <div class="row">
<q-img <div style="position: relative;width: 80px;">
:src="trip.CoverImageList.length>0&&trip.CoverImageList[0].Url?trip.CoverImageList[0].Url:''" <div
class="rounded-borders" style="position: absolute; left: 0; top: 0; right: 0; bottom: 0"
spinner-color="grey-3" class="overflow-hidden rounded-borders"
style="width: 80px" >
/> <q-img
:src="trip.CoverImageList.length>0&&trip.CoverImageList[0].Url?trip.CoverImageList[0].Url:''"
class="rounded-borders"
spinner-color="grey-3"
style="width: 80px"
/>
</div>
</div>
<div class="q-ml-md col"> <div class="q-ml-md col">
<div class="text-subtitle1 ellipsis"> <div class="text-subtitle1 ellipsis">
{{ trip.Name }} {{ trip.Name }}
...@@ -481,12 +488,19 @@ ...@@ -481,12 +488,19 @@
> >
<div class="text-subtitle1 text-weight-bolder">付款明細</div> <div class="text-subtitle1 text-weight-bolder">付款明細</div>
<div class="row q-mt-md"> <div class="row q-mt-md">
<q-img <div style="position: relative;width: 80px;">
:src="trip.CoverImageList.length>0&&trip.CoverImageList[0].Url?trip.CoverImageList[0].Url:''" <div
class="rounded-borders" style="position: absolute; left: 0; top: 0; right: 0; bottom: 0"
spinner-color="grey-3" class="overflow-hidden rounded-borders"
style="width: 80px" >
/> <q-img
:src="trip.CoverImageList.length>0&&trip.CoverImageList[0].Url?trip.CoverImageList[0].Url:''"
class="rounded-borders"
spinner-color="grey-3"
style="width: 80px"
/>
</div>
</div>
<div class="q-ml-md col"> <div class="q-ml-md col">
<div class="text-subtitle1 ellipsis"> <div class="text-subtitle1 ellipsis">
{{ trip.Name }} {{ trip.Name }}
...@@ -1084,6 +1098,9 @@ export default { ...@@ -1084,6 +1098,9 @@ export default {
(r) => { (r) => {
if (r.data.resultCode == 1) { if (r.data.resultCode == 1) {
this.trip = r.data.data; this.trip = r.data.data;
this.trip.CoverImageList = this.trip.CoverImageList.filter(item=>{
return item.Url!=null
})
this.price = this.trip.VisaProductInfo; this.price = this.trip.VisaProductInfo;
// this.price.realPrice = this.price.originalB2CPrice; // this.price.realPrice = this.price.originalB2CPrice;
// if ( // if (
......
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