Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
million
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
viitto
million
Commits
349d07d1
Commit
349d07d1
authored
Nov 22, 2024
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
111
parent
7abed8b6
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
614 additions
and
712 deletions
+614
-712
kkday.vue
src/components/searchProductdata/kkday.vue
+242
-306
list.vue
src/components/searchProductdata/list.vue
+96
-79
detailsProduct.vue
src/pages/detailsProduct.vue
+276
-327
No files found.
src/components/searchProductdata/kkday.vue
View file @
349d07d1
...
...
@@ -5,12 +5,31 @@
>
<!-- 移动端 -->
<div
v-if=
"$q.platform.is.mobile"
>
<div
class=
"flex"
>
<div
@
click=
"showAddress = true"
class=
"nav-item"
>
目的地
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left:4px"
></i></div>
<div
@
click=
"showCategory = true"
class=
"nav-item"
>
商品類別
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left:4px"
></i></div>
<div
@
click=
"showDate = true"
class=
"nav-item"
>
旅程時間
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left:4px"
></i></div>
<div
@
click=
"showPrice = true"
class=
"nav-item"
>
價錢/时间
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left:4px"
></i></div>
<div
@
click=
"showAddress = true"
class=
"nav-item"
>
目的地
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left: 4px"
></i>
</div>
<div
@
click=
"showCategory = true"
class=
"nav-item"
>
商品類別
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left: 4px"
></i>
</div>
<div
@
click=
"showDate = true"
class=
"nav-item"
>
旅程時間
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left: 4px"
></i>
</div>
<div
@
click=
"showPrice = true"
class=
"nav-item"
>
價錢/时间
<i
class=
"iconfont iconarrowdown text-grey-6"
style=
"margin-top: 3px; margin-left: 4px"
></i>
</div>
</div>
<popup
mode=
"top"
v-model=
"showAddress"
>
<q-card
flat
class=
"rounded-borders q-py-md"
>
...
...
@@ -51,8 +70,8 @@
tick-strategy=
"leaf"
@
update:ticked=
"handleTicked"
:ticked=
"ticked"
/>
</q-card
></popup>
/>
</q-card
></popup>
<popup
mode=
"top"
v-model=
"showDate"
>
<q-card
flat
class=
"rounded-borders q-mt-lg overflow-hidden"
>
<div
class=
"q-my-sm q-mx-lg f20 bold"
>
旅程時間
</div>
...
...
@@ -61,11 +80,7 @@
v-for=
"(y, yi) in dayArray"
:key=
"yi"
>
<q-checkbox
v-model=
"y.checked"
size=
"xs"
@
input=
"changeTripDayHandler"
/>
<q-checkbox
v-model=
"y.checked"
size=
"xs"
@
input=
"changeTripDayHandler"
/>
<span
class=
"col text-grey-8 text-subtitle2 text-regular q-mt-xs"
style=
"font-weight: 400"
...
...
@@ -76,7 +91,6 @@
</q-card>
</popup>
<popup
mode=
"top"
v-model=
"showPrice"
>
<q-card
flat
class=
"rounded-borders q-pa-md q-mt-lg"
>
<div
class=
"text-subtitle1 text-weight-bold"
>
價錢篩選(CNY)
</div>
<div
class=
"q-mt-md text-grey-6 text-subtitle2 text-regular"
>
...
...
@@ -90,21 +104,17 @@
@
change=
"testHandler"
color=
"primary"
class=
"q-mt-md"
/>
</q-card
><q-card
flat
class=
"rounded-borders q-mt-lg row no-padding q-mb-lg"
>
/>
</q-card
><q-card
flat
class=
"rounded-borders q-mt-lg row no-padding q-mb-lg"
>
<div
class=
"q-px-md q-py-sm
"
class=
"q-px-md q-py-sm
"
style=
"border-right: 1px solid #eee; border-radius: 0 !important"
>
<q-icon
name=
"iconfont iconigw-l-date-trade"
size=
"24px"
/>
</div>
<div
class=
"row items-center justify-center col"
>
<span
class=
"text-grey-8"
>
{{
msg
.
startDate
?
`${msg.startDate
}
- ${msg.endDate
}
`
:
"篩選出發日期"
}}
{{
msg
.
startDate
?
`${msg.startDate
}
- ${msg.endDate
}
`
:
"篩選出發日期"
}}
<
/span
>
<
q
-
popup
-
proxy
:
offset
=
"[0, 0]"
ref
=
"qDateProxy"
>
<
div
>
...
...
@@ -117,8 +127,8 @@
><
/q-date
>
<
/div
>
<
/q-popup-proxy
>
<
/div
>
<
/q-card
></
popup
>
<
/div> </
q
-
card
><
/popup
>
<
/div
>
<
div
v
-
else
class
=
"col-3"
:
class
=
"$q.platform.is.desktop ? 'q-mr-lg' : 'q-ma-md'"
>
<
q
-
card
flat
class
=
"rounded-borders q-py-md"
>
...
...
@@ -168,11 +178,7 @@
<
/div
>
<
div
class
=
"row items-center justify-center col"
>
<
span
class
=
"text-grey-8"
>
{{
msg
.
startDate
?
`${msg.startDate
}
- ${msg.endDate
}
`
:
"篩選出發日期"
}}
{{
msg
.
startDate
?
`${msg.startDate
}
- ${msg.endDate
}
`
:
"篩選出發日期"
}}
<
/span
>
<
q
-
popup
-
proxy
:
offset
=
"[0, 0]"
ref
=
"qDateProxy"
>
<
div
>
...
...
@@ -214,11 +220,7 @@
v
-
for
=
"(y, yi) in dayArray"
:
key
=
"yi"
>
<
q
-
checkbox
v
-
model
=
"y.checked"
size
=
"xs"
@
input
=
"changeTripDayHandler"
/>
<
q
-
checkbox
v
-
model
=
"y.checked"
size
=
"xs"
@
input
=
"changeTripDayHandler"
/>
<
span
class
=
"col text-grey-8 text-subtitle2 text-regular q-mt-xs"
style
=
"font-weight: 400"
...
...
@@ -248,10 +250,7 @@
:
label
=
"x.Name"
/>
<
/div
>
<
div
class
=
"q-pa-md row items-center"
style
=
"border-top: 1px solid #eee"
>
<
div
class
=
"q-pa-md row items-center"
style
=
"border-top: 1px solid #eee"
>
<
span
class
=
"f12"
>
排序:
<
/span
>
<
q
-
chip
square
...
...
@@ -270,13 +269,14 @@
>
<
/div
>
<
/div
>
<
div
class
=
"q-mt-lg"
v
-
if
=
"!$q.loading.isActive &&
DataList
&& DataList.length > 0"
>
<
div
class
=
"q-mt-lg"
v
-
if
=
"!$q.loading.isActive &&
DataList
&& DataList.length > 0"
>
<
div
class
=
"rounded-borders cursor-pointer overflow-hidden bg-white"
:
class
=
"$q.platform.is.desktop ? 'row q-mb-md' : 'colmuns q-ma-md'"
v
-
for
=
"(x, i) in DataList"
:
key
=
"i"
>
<
template
v
-
if
=
"x.imgCover&&x.imgCover.length>0"
>
v
-
for
=
"(x, i) in DataList"
:
key
=
"i"
>
<
template
v
-
if
=
"x.imgCover && x.imgCover.length > 0"
>
<
q
-
img
:
src
=
"x.imgCover[0].url"
:
ratio
=
"1"
...
...
@@ -298,10 +298,13 @@
/>
<
/template
>
<
div
class
=
"q-pa-md col column"
>
<
div
class
=
"text-subtitle1 text-weight-bold text-grey-9"
@
click
=
"GotoDetails(x)"
>
<
div
class
=
"text-subtitle1 text-weight-bold text-grey-9"
@
click
=
"GotoDetails(x)"
>
{{
x
.
title
}}
<
/div
>
<
div
class
=
"col"
>
<
div
class
=
"col"
>
<
div
class
=
"row items-center q-my-sm"
@
click
=
"GotoDetails(x)"
>
<
q
-
chip
style
=
"background: #26a69a1a"
...
...
@@ -317,31 +320,38 @@
:
label
=
"x.ltName"
/>
<
/div
>
<
div
class
=
"text-subtitle2 text-grey-6 text-weight-regular ellipsis-2-lines"
style
=
"line-height: 1.6"
@
click
=
"GotoDetails(x)"
>
<
div
class
=
"text-subtitle2 text-grey-6 text-weight-regular ellipsis-2-lines"
style
=
"line-height: 1.6"
@
click
=
"GotoDetails(x)"
>
{{
x
.
productRecommend
}}
<
/div
>
<
div
class
=
"row items-center f12 text-grey-6 q-mt-md"
>
<
q
-
icon
size
=
"12px"
name
=
"iconfont icondingweixiao"
class
=
"q-mr-sm"
/>
<
q
-
icon
size
=
"12px"
name
=
"iconfont icondingweixiao"
class
=
"q-mr-sm"
/>
<
span
class
=
"q-mr-lg"
@
click
=
"GotoDetails(x)"
>
{{
x
.
countryName
}}
<
/span
>
<
q
-
icon
size
=
"12px"
name
=
"iconfont iconigw-l-date-trade"
class
=
"q-mr-sm"
><
/q-icon
>
<
template
v
-
if
=
"x.startDateList&&x.startDateList.length>0"
>
<
template
v
-
if
=
"x.startDateList.length>1"
>
<
q
-
badge
outline
:
color
=
"x.index==index?'secondary':'blue-grey-11'"
:
label
=
"item"
v
-
for
=
"(item,index) in x.startDateList"
:
key
=
"index"
style
=
"margin-right:5px;margin-bottom:7px;"
@
click
=
"SwitchTCID(x,i,index)"
/>
<
template
v
-
if
=
"x.startDateList && x.startDateList.length > 0"
>
<
template
v
-
if
=
"x.startDateList.length > 1"
>
<
q
-
badge
outline
:
color
=
"x.index == index ? 'secondary' : 'blue-grey-11'"
:
label
=
"item"
v
-
for
=
"(item, index) in x.startDateList"
:
key
=
"index"
style
=
"margin-right: 5px; margin-bottom: 7px"
@
click
=
"SwitchTCID(x, i, index)"
/>
<
/template
>
<
template
v
-
else
>
<
q
-
badge
outline
color
=
"secondary"
:
label
=
"x.startDateList[0]"
/>
<
q
-
badge
outline
color
=
"secondary"
:
label
=
"x.startDateList[0]"
/>
<
/template
>
<
/template
>
<
/div
>
<
/div
>
<
div
class
=
"row items-end"
@
click
=
"GotoDetails(x)"
>
<
div
class
=
"col f12"
>
...
...
@@ -351,9 +361,7 @@
style
=
"border-right: 1px solid #efefef"
>
{{
x
.
surplus
}}
<
/span> --
>
<
span
>
行程天數:
<
/span
>
<
span
class
=
"text-secondary text-weight-bold"
>
{{
x
.
dayNum
}}
天
<
/spa
n
>
<
span
class
=
"text-secondary text-weight-bold"
>
{{
x
.
dayNum
}}
天
<
/span
>
<
/div
>
<
div
class
=
"text-h6 product-price"
>
CNY
:
{{
x
.
b2CPrice
}}
<
span
class
=
"price-stuff"
>
元
<
/span
>
...
...
@@ -407,7 +415,7 @@ import popup from "../props/index";
import { date
}
from "
quasar
";
export default {
props: ["
qMsg
"],
components: {
popup
}
,
components: {
popup
}
,
data() {
return {
showAddress: false,
...
...
@@ -482,7 +490,7 @@ export default {
text: "
10
天以上
",
}
,
],
d
ataList: [],
D
ataList: [],
sortArray: [
{
label: "
默认排序
",
...
...
@@ -522,46 +530,42 @@ export default {
this.dayArray.forEach((x) => {
x.checked = false;
}
);
this.msg.startDate = date.formatDate(new Date(this.qMsg.startDate), "
YYYY
/
MM
/
DD
")
this.msg.endDate = date.formatDate(new Date(this.qMsg.endDate), "
YYYY
/
MM
/
DD
")
this.msg.startDate = date.formatDate(new Date(this.qMsg.startDate), "
YYYY
/
MM
/
DD
")
;
this.msg.endDate = date.formatDate(new Date(this.qMsg.endDate), "
YYYY
/
MM
/
DD
")
;
this.dateRange = { from: this.msg.startDate, to: this.msg.endDate
}
;
}
,
mounted() {
let LineIdList=[];
if( this.msg.LineIds&& this.msg.LineIds.length>0)
{
LineIdList= this.msg.LineIds.split("
;
");
}
let SeriesIdList= [];
if( this.msg.SeriesIds&& this.msg.SeriesIds.length>0)
{
SeriesIdList= this.msg.SeriesIds.split("
;
");
}
if((LineIdList&&LineIdList.length>0)||(SeriesIdList&&SeriesIdList.length>0)){
let LineIdList = [];
if (this.msg.LineIds && this.msg.LineIds.length > 0) {
LineIdList = this.msg.LineIds.split("
;
");
}
let SeriesIdList = [];
if (this.msg.SeriesIds && this.msg.SeriesIds.length > 0) {
SeriesIdList = this.msg.SeriesIds.split("
;
");
}
if (
(LineIdList && LineIdList.length > 0) ||
(SeriesIdList && SeriesIdList.length > 0)
) {
let arr = [];
this.goodsType.forEach((x) => {
let lineIdIndex= LineIdList.findIndex(yId=>x.Id.slice(2)==
yId);
if (lineIdIndex!=
-1) {
let lineIdIndex = LineIdList.findIndex((yId) => x.Id.slice(2) ==
yId);
if (lineIdIndex !=
-1) {
arr.push(x.Id);
}
x.children.forEach((y) => {
if(lineIdIndex!=-1){
if (lineIdIndex != -1) {
arr.push(y.Id);
}
else{
let seriesIdIndex= SeriesIdList.findIndex(yId=>y.Id.slice(2)==yId);
}
else {
let seriesIdIndex = SeriesIdList.findIndex((yId) => y.Id.slice(2) == yId);
if (seriesIdIndex!=
-1) {
if (seriesIdIndex !=
-1) {
arr.push(y.Id);
}
}
}
);
}
);
this.ticked = arr;
console.log("
this
.
ticked
",this.ticked);
}
}
,
methods: {
...
...
@@ -569,12 +573,12 @@ export default {
console.log("
handleSelected
", target);
}
,
handleTicked(target) {
this.msg.pageIndex = 1
this.msg.pageIndex = 1
;
this.ticked = target;
this.goSearchHandler();
}
,
handleAreaTicked(target) {
this.msg.pageIndex = 1
this.msg.pageIndex = 1
;
this.msg.placeIds = this.getChoseAddressCity().join("
,
");
this.goSearchHandler();
}
,
...
...
@@ -623,7 +627,7 @@ export default {
chosenSortHandler(x) {
this.msg.orderBy = x.value;
this.msg.pageIndex = 1
this.msg.pageIndex = 1
;
this.goSearchHandler();
}
,
getChoseAddressCity() {
...
...
@@ -631,10 +635,7 @@ export default {
function treeToArray(tree) {
return tree.reduce((res, item) => {
const { children, ...i
}
= item;
return res.concat(
i,
children && children.length ? treeToArray(children) : []
);
return res.concat(i, children && children.length ? treeToArray(children) : []);
}
, []);
}
const areaList = treeToArray(this.areaList);
...
...
@@ -648,20 +649,6 @@ export default {
}
,
changeTripDayHandler() {
this.$forceUpdate();
// this.msg.minTripDay = "
0
";
// this.msg.maxTripDay = "
0
";
// this.dayArray.forEach(x => {
// if (x.checked) {
// this.msg.minPrice =
// this.msg.minPrice > x.min ? x.min : this.msg.minPrice;
// this.msg.maxPrice =
// this.msg.maxPrice < x.max ? x.max : this.msg.maxPrice;
//
}
//
}
);
// this.msg.minTripDay =
// this.msg.minTripDay == "
0
" ? "" : this.msg.minTripDay;
// this.msg.maxTripDay =
// this.msg.maxTripDay == "
0
" ? "" : this.msg.maxTripDay;
let arr = [];
this.dayArray.forEach((item) => {
if (item.checked) {
...
...
@@ -669,117 +656,78 @@ export default {
}
}
);
this.msg.dayNumList = arr;
this.msg.pageIndex = 1
this.msg.pageIndex = 1
;
this.goSearchHandler();
}
,
optionsFn(cd) {
return (
cd >=
date.formatDate(date.addToDate(new Date(), { days: 1
}
), "
YYYY
/
MM
/
DD
")
);
return cd >= date.formatDate(date.addToDate(new Date(), { days: 1
}
), "
YYYY
/
MM
/
DD
");
}
,
testHandler(e) {
this.$forceUpdate();
this.msg.minPrice = e.min;
this.msg.maxPrice = e.max;
this.msg.pageIndex = 1
this.msg.pageIndex = 1
;
this.goSearchHandler();
}
,
dateRangeHandler(e) {
this.msg.startDate = `${e.from.year
}
/${e.from.month
}
/${e.from.day
}
`;
this.msg.endDate = `${e.to.year
}
/${e.to.month
}
/${e.to.day
}
`;
this.$refs.qDateProxy.hide();
this.msg.pageIndex = 1
this.msg.pageIndex = 1
;
this.goSearchHandler();
}
,
initGoods() {
let arr = [];
// SeriesIds:"",
//LineIds:"",
let LineIdList=[];
if( this.msg.LineIds&& this.msg.LineIds.length>0)
{
LineIdList= this.msg.LineIds.split("
;
");
let LineIdList = [];
if (this.msg.LineIds && this.msg.LineIds.length > 0) {
LineIdList = this.msg.LineIds.split("
;
");
}
let SeriesIdList= [];
if( this.msg.SeriesIds&& this.msg.SeriesIds.length>0)
{
SeriesIdList= this.msg.SeriesIds.split("
;
");
let SeriesIdList = [];
if (this.msg.SeriesIds && this.msg.SeriesIds.length > 0) {
SeriesIdList = this.msg.SeriesIds.split("
;
");
}
this.apipost(
"
b2c_get_Get
AllLineList
",
"
b2c_get_Get
B2CQueryCondition
",
this.msg,
(res) => {
if (res.data.resultCode == 1) {
var jObj = res.data.data;
var jObj = res.data.data
.LineList
;
jObj.forEach((x) => {
x.checked = false;
x.explsed = false;
x.isShow = true;
x.children = x.SubList;
let lineIdIndex
= LineIdList.findIndex(yId=>x.Id.slice(2)==
yId);
let lineIdIndex
= LineIdList.findIndex((yId) => x.Id.slice(2) ==
yId);
x.children.forEach((y) => {
y.checked = false;
y.explsed = false;
y.isShow = true;
if(lineIdIndex!=-1)
{
if (lineIdIndex != -1)
{
arr.push(y.Id);
this.ticked.push(y.Id);
}
else{
let seriesIdIndex= SeriesIdList.findIndex(yId=>y.Id.slice(2)==yId);
if (seriesIdIndex!=-1) {
}
else {
let seriesIdIndex = SeriesIdList.findIndex(
(yId) => y.Id.slice(2) == yId
);
if (seriesIdIndex != -1) {
arr.push(y.Id);
this.ticked.push(y.Id);
}
}
}
);
this.goodsType.push(x);
}
);
console.log("
arr
",arr);
if(this.ticked&&this.ticked.length>0){
if (this.ticked && this.ticked.length > 0) {
this.msg.webSiteCategoryIds = this.ticked.join("
,
");
this.goSearchHandler();
}
else
{
}
else
{
this.goSearchHandler();
}
}
else this.goSearchHandler()
}
else this.goSearchHandler();
}
,
(err) => {
}
);
//let jObj = JSON.parse(window.localStorage.getItem("
baseifo
"));
// jObj.CategoryList.forEach((x) => {
// x.checked = false;
// x.explsed = false;
// x.isShow = true;
// x.children = x.SubList;
// x.children.forEach((y) => {
// y.checked = false;
// y.explsed = false;
// y.isShow = true;
// if (y.Id === this.msg.categoryId) {
// arr.push(y.Id);
//
}
// if (y.SubList && y.SubList.length) {
// y.children = y.SubList;
// y.children.forEach((z) => {
// z.checked = false;
// z.explsed = false;
// z.isShow = true;
// if (z.Id === this.msg.categoryId) {
// arr.push(z.Id);
//
}
// if (y.Id === this.msg.categoryId) {
// arr.push(z.Id);
//
}
//
}
);
//
}
//
}
);
// this.goodsType.push(x);
// console.log("
goodsType
",this.goodsType);
//
}
);
this.goodsTypeJSON = JSON.stringify(this.goodsType);
if (this.msg.categoryId) {
this.$nextTick(() => {
...
...
@@ -840,21 +788,8 @@ export default {
}
);
this.areaList = tree.children;
// this.areaList.forEach(x => {
// x.isShow = x.Name.indexOf(v) != -1;
// x.isShowChild = false;
// x.SubList.forEach(y => {
// y.isShow = y.Name.indexOf(v) != -1;
// if (y.isShow) {
// x.isShow = true;
// x.isShowChild = true;
//
}
//
}
);
//
}
);
}
,
goSearchHandler() {
// this.msg.placeIds = this.areaTicked.join("
,
");
this.$q.loading.show();
this.DataList = [];
let minTripDay = -1,
...
...
@@ -893,12 +828,11 @@ export default {
this.msg,
(res) => {
this.$q.loading.hide();
console.log("
b2c_get_GetB2C2024TravelProductPage
", res);
if (res.data.resultCode == 1) {
this.PageCount = res.data.data.pageCount;
this.TotalCount = res.data.data.count;
var tempArray = res.data.data.pageData.list;
console.log("
getSearch
data
", tempArray);
if (tempArray && tempArray.length > 0) {
this.DataList = tempArray;
this.renderSearchInfo(res.data.data.pageData.condition);
...
...
@@ -964,8 +898,7 @@ export default {
}
);
this.goodsType = category.children;
// this.ticked = categoryInfo;
console.log("
this
.
areaListJSONTMP
", this.areaListJSONTMP, this.areaList);
this.priceModel = { min: priceInfo.minPrice, max: priceInfo.maxPrice
}
;
let arr = [];
dayInfo.forEach((item) => {
...
...
@@ -983,18 +916,21 @@ export default {
}
,
GotoDetails(item) {
this.CommonJump('/detailsProduct/' + encodeURIComponent(item.id)+ "
/
" + item.configId,{
}
, "
blank
");
this.CommonJump(
"
/
detailsProduct
/
" + encodeURIComponent(item.id) + "
/
" + item.configId,
{
}
,
"
blank
"
);
}
,
SwitchTCID(obj,i,index) {
if(this.DataList&&this.DataList.length>0){
let nowobj= JSON.parse(JSON.stringify(obj));
console.log("
nowobj
",nowobj.startDateList);
SwitchTCID(obj, i, index) {
if (this.DataList && this.DataList.length > 0) {
let nowobj = JSON.parse(JSON.stringify(obj));
this.DataList[i] = {
...nowobj.priceList[index]
}
this.DataList[i].index
=
index;
this.DataList[i].startDateList
=
nowobj.startDateList;
this.DataList[i].priceList
=
nowobj.priceList;
...nowobj.priceList[index]
,
}
;
this.DataList[i].index
=
index;
this.DataList[i].startDateList
=
nowobj.startDateList;
this.DataList[i].priceList
=
nowobj.priceList;
this.$forceUpdate();
}
}
,
...
...
@@ -1004,7 +940,7 @@ export default {
<style>
.addr-list:hover {
background: #
E3F2FD
;
background: #
e3f2fd
;
}
</style>
<style lang="
scss
" scoped>
...
...
src/components/searchProductdata/list.vue
View file @
349d07d1
...
...
@@ -2,39 +2,50 @@
<!-- 列表 -->
<div
class=
"group-result-list"
>
<div
class=
"group-statis-block"
>
<div
class=
"group-share"
style=
"display:none;
"
></div>
<div
class=
"group-share"
style=
"display: none
"
></div>
<div
class=
"group-statis-detail"
>
<span
class=
"title"
v-if=
"qMsg.searchKey"
>
{{
qMsg
.
searchKey
}}
:
</span>
<span
class=
"title"
v-if=
"qMsg.searchKey"
>
{{
qMsg
.
searchKey
}}
:
</span>
找到
<span
class=
"num"
>
{{
qMsg
.
TotalCount
}}
</span>
個行程
<span
class=
"pc"
>
,目前在第
<span
style=
"color: #7f7f7f;"
>
{{
qMsg
.
pageIndex
}}
</span>
頁
</span>
<span
class=
"num"
>
{{
qMsg
.
TotalCount
}}
</span>
個行程
<span
class=
"pc"
>
,目前在第
<span
style=
"color: #7f7f7f"
>
{{
qMsg
.
pageIndex
}}
</span>
頁
</span
>
</div>
</div>
<div>
<div
class=
"group-box"
v-for=
"(itemf,
indexf) in DataList"
:key=
"indexf"
>
<a
class=
"group-cover"
>
<template
v-if=
"itemf.imgCover&&itemf.imgCover.length>
0"
>
<div
class=
"group-box"
v-for=
"(itemf,
indexf) in DataList"
:key=
"indexf"
>
<a
class=
"group-cover"
>
<template
v-if=
"itemf.imgCover && itemf.imgCover.length >
0"
>
<img
:src=
"itemf.imgCover[0].url"
/>
</
template
>
</a>
<div
class=
"group-main"
>
<div
class=
"group-info"
>
<div
class=
"group-name"
style=
"margin-bottom:5px;cursor:pointer"
@
click=
"GotoDetails(itemf)"
>
{{itemf.title}}
<div
class=
"group-name"
style=
"margin-bottom: 5px; cursor: pointer"
@
click=
"GotoDetails(itemf)"
>
{{ itemf.title }}
</div>
<div
class=
"group-detail"
@
click=
"GotoDetails(itemf)"
>
<i
class=
"iconfont iconaddress"
></i>
<span>
{{itemf.countryName
}}
</span>
<span>
{{ itemf.countryName
}}
</span>
</div>
<div
class=
"group-detail"
@
click=
"GotoDetails(itemf)"
>
<i
class=
"iconfont icontime"
></i>
<span>
{{itemf.dayNum
}} 天
</span>
<span>
{{ itemf.dayNum
}} 天
</span>
</div>
<ul
class=
"group-list"
>
<li>
<
template
v-if=
"itemf.PriceList&&itemf.PriceList.length>0"
>
<div
v-for=
"(item,index) in itemf.priceList"
:key=
"index"
style=
"margin-right:5px;margin-bottom:7px;"
@
click=
"SwitchTCID(itemf,indexf,index)"
>
<a>
{{
item
.
StartDate
}}
</a>
<
template
v-if=
"itemf.PriceList && itemf.PriceList.length > 0"
>
<div
v-for=
"(item, index) in itemf.priceList"
:key=
"index"
style=
"margin-right: 5px; margin-bottom: 7px"
@
click=
"SwitchTCID(itemf, indexf, index)"
>
<a>
{{
item
.
StartDate
}}
</a>
</div>
</
template
>
</li>
...
...
@@ -43,52 +54,58 @@
<div
class=
"price-info"
@
click=
"GotoDetails(itemf)"
>
<div
class=
"price-wrap"
>
<div
class=
"price_Search"
>
<small
class=
"price_unit"
>
TWD$
</small>
{{itemf.b2BPrice
}}
<small
class=
"price_unit"
>
TWD$
</small>
{{ itemf.b2BPrice
}}
</div>
<a
class=
"btn_warning"
@
click=
"GotoDetails(itemf)"
style=
"cursor:pointer"
>
更多出發日
</a>
<a
class=
"btn_warning"
@
click=
"GotoDetails(itemf)"
style=
"cursor: pointer"
>
更多出發日
</a
>
</div>
</div>
</div>
</div>
<div
style=
"display:flex;justify-content: center;"
>
<q-pagination
v-if=
"qMsg.PageCount>1"
v-model=
"qMsg.pageIndex"
:max=
"qMsg.PageCount"
@
input=
"gerOrderList()"
:direction-links=
"true"
>
<div
style=
"display: flex; justify-content: center"
>
<q-pagination
v-if=
"qMsg.PageCount > 1"
v-model=
"qMsg.pageIndex"
:max=
"qMsg.PageCount"
@
input=
"gerOrderList()"
:direction-links=
"true"
>
</q-pagination>
</div>
</div>
</div>
</template>
<
script
>
export
default
{
export
default
{
props
:
[
"DataList"
,
"qMsg"
],
data
()
{
return
{
};
return
{};
},
methods
:
{
GotoDetails
(
item
)
{
this
.
CommonJump
(
'/details/'
+
encodeURIComponent
(
item
.
id
)
+
"/"
+
item
.
configId
,
{},
"blank"
);
this
.
CommonJump
(
"/details/"
+
encodeURIComponent
(
item
.
id
)
+
"/"
+
item
.
configId
,
{},
"blank"
);
},
//调用
gerOrderList
()
{
this
.
$emit
(
'getPage'
)
gerOrderList
()
{
this
.
$emit
(
"getPage"
);
},
SwitchTCID
(
obj
,
i
,
index
)
{
if
(
this
.
DataList
&&
this
.
DataList
.
length
>
0
){
let
nowobj
=
JSON
.
parse
(
JSON
.
stringify
(
obj
));
console
.
log
(
"nowobj"
,
nowobj
.
startDateList
);
SwitchTCID
(
obj
,
i
,
index
)
{
if
(
this
.
DataList
&&
this
.
DataList
.
length
>
0
)
{
let
nowobj
=
JSON
.
parse
(
JSON
.
stringify
(
obj
));
this
.
DataList
[
i
]
=
{
...
nowobj
.
priceList
[
index
]
}
this
.
DataList
[
i
].
index
=
index
;
this
.
DataList
[
i
].
startDateList
=
nowobj
.
startDateList
;
this
.
DataList
[
i
].
priceList
=
nowobj
.
priceList
;
...
nowobj
.
priceList
[
index
]
,
}
;
this
.
DataList
[
i
].
index
=
index
;
this
.
DataList
[
i
].
startDateList
=
nowobj
.
startDateList
;
this
.
DataList
[
i
].
priceList
=
nowobj
.
priceList
;
this
.
$forceUpdate
();
}
},
}
}
},
};
</
script
>
src/pages/detailsProduct.vue
View file @
349d07d1
<
template
>
<div
class=
""
style=
"min-height: 80vh;overflow: hidden;"
>
<div
v-if=
"dataList && !$q.loading.isActive"
<div
class=
""
style=
"min-height: 80vh; overflow: hidden"
>
<div
v-if=
"dataList && !$q.loading.isActive"
class=
"relative"
style=
"margin: auto;"
:style=
"
{'max-width': $q.platform.is.desktop?'1200px':'100%'}">
style=
"margin: auto"
:style=
"
{ 'max-width': $q.platform.is.desktop ? '1200px' : '100%' }"
>
<div
style=
"
position: fixed;
...
...
@@ -31,12 +33,9 @@
<span
class=
"col product-price text-subtitle1 text-weight-bold"
style=
"text-align: left"
v-if=
"dataList.priceList.length>0"
>
<span
>
CNY
{{
moneyFormat
(
dataList
.
priceList
[
0
].
originalB2CPrice
,
0
)
}}
</span
v-if=
"dataList.priceList.length > 0"
>
<span>
CNY
{{
moneyFormat
(
dataList
.
priceList
[
0
].
originalB2CPrice
,
0
)
}}
</span>
<span
class=
"q-ml-sm f12 text-grey-7"
>
起
</span>
</span>
<q-btn
...
...
@@ -51,7 +50,7 @@
<div
v-if=
"dataList"
style=
"margin-left: auto; margin-right: auto"
:style=
"
{
'max-width': $q.platform.is.desktop?'1200px':'100%'
}"
:style=
"
{
'max-width': $q.platform.is.desktop ? '1200px' : '100%'
}"
:class="{ 'q-px-md': $q.screen.width
<
1220
}"
>
<div
class=
"row items-center q-mt-md q-mb-lg"
>
...
...
@@ -66,16 +65,8 @@
class=
"cursor-pointer"
@
click=
"CommonJump('/index',
{})"
/>
<q-breadcrumbs-el
:label=
"dataList.aimPlaceName"
class=
"cursor-pointer"
/>
<!--
<q-breadcrumbs-el>
<span
v-for=
"(x, i) in citys"
:key=
"i"
>
<span
class=
"cursor-pointer"
>
{{
x
}}
</span>
<span
v-if=
"i + 1 != citys.length"
class=
"q-mr-sm"
>
,
</span>
</span>
</q-breadcrumbs-el>
-->
<q-breadcrumbs-el
:label=
"dataList.aimPlaceName"
class=
"cursor-pointer"
/>
<q-breadcrumbs-el
v-if=
"$q.platform.is.desktop"
:label=
"dataList.title"
...
...
@@ -122,11 +113,7 @@
style=
"width: 80%"
class=
"q-mx-sm"
>
<q-img
:src=
"item.Url"
spinner-color=
"grey"
spinner-size=
"20px"
/>
<q-img
:src=
"item.Url"
spinner-color=
"grey"
spinner-size=
"20px"
/>
</slideritem>
<div
slot=
"loading"
>
loading...
</div>
</slider>
...
...
@@ -143,15 +130,11 @@
<div
class=
"col q-mr-lg"
>
<div
class=
"text-h6 ellipsis-2-lines"
>
{{
dataList
.
title
}}
</div>
<div
class=
"q-mt-md f12 text-grey-6"
>
<q-icon
name=
"iconfont icondingweixiao"
size=
"16px"
class=
"q-mr-sm"
/>
<q-icon
name=
"iconfont icondingweixiao"
size=
"16px"
class=
"q-mr-sm"
/>
<span
>
{{
dataList
.
aimPlaceName
}}
<template
v-if=
"citys.length
>
0"
>
<template
v-if=
"citys.length
>
0"
>
<span
class=
"q-mx-sm"
>
途徑:
</span>
<span
v-for=
"(x, i) in citys"
:key=
"i"
>
...
...
@@ -175,12 +158,6 @@
icon=
"iconfont icontime"
:label=
"` 行程時間 ${dataList.dayList.length} 天`"
/>
<!-- <q-chip
class="transparent q-mr-xl no-padding"
square
icon="iconfont iconnetwork-fill"
label="日本語/中文 導覽"
/> -->
<q-chip
class=
"transparent q-mr-xl no-padding"
square
...
...
@@ -194,15 +171,10 @@
class=
"bg-grey-3 rounded-borders q-px-md"
:class=
"{
'q-py-lg': $q.platform.is.desktop,
'row justify-between items-center q-mt-sm q-py-sm':
$q.platform.is.mobile,
'row justify-between items-center q-mt-sm q-py-sm': $q.platform.is.mobile,
}"
>
<div
class=
"product-price text-h6"
v-if=
"dataList.priceList.length > 0"
>
<!-- CNY:{{ dataList. }} -->
<div
class=
"product-price text-h6"
v-if=
"dataList.priceList.length > 0"
>
CNY:{{ moneyFormat(dataList.priceList[0].originalB2CPrice, 0) }}
<span
class=
"f12 text-grey-6"
>
起
</span>
</div>
...
...
@@ -265,24 +237,14 @@
></q-tab>
</q-tabs>
</div>
<div
v-if=
"dataList"
class=
"q-pa-lg bg-grey-3 q-mt-lg text-grey-9"
ref=
"pricelist"
>
<div
v-if=
"dataList"
class=
"q-pa-lg bg-grey-3 q-mt-lg text-grey-9"
ref=
"pricelist"
>
<div
style=
"max-width: 1200px; margin-left: auto; margin-right: auto"
>
<div
class=
"text-h6"
>
選擇方案
</div>
<div
class=
"rounded-borders bg-white q-pa-md q-mt-md"
v-if=
"$q.platform.is.mobile"
>
<q-field
class=
"q-mt-md"
stack-label
label=
"選擇日期、選項"
standout
dense
>
<q-field
class=
"q-mt-md"
stack-label
label=
"選擇日期、選項"
standout
dense
>
<div
class=
"self-center full-width no-outline"
tabindex=
"0"
>
{{ currentPrice.startDate }}
</div>
...
...
@@ -304,9 +266,7 @@
></order-preview>
</div>
<div
class=
"text-h6 q-pt-lg"
v-if=
"$q.platform.is.mobile"
>
所選方案詳情
</div>
<div
class=
"text-h6 q-pt-lg"
v-if=
"$q.platform.is.mobile"
>
所選方案詳情
</div>
<div
class=
"bg-white rounded-borders q-mt-md"
v-if=
"dataList.priceList.length > 0"
...
...
@@ -333,8 +293,7 @@
v-for=
"(x, i) in warnBuy"
:class=
"{
'q-mt-md':
$q.platform.is.desktop
| (i != 0 && $q.platform.is.mobile),
$q.platform.is.desktop | (i != 0 && $q.platform.is.mobile),
}"
:key=
"i"
>
...
...
@@ -345,11 +304,11 @@
</div>
<div
class=
""
v-if=
"$q.platform.is.desktop"
>
<div
class=
"row items-center"
>
<span
class=
"product-price text-h6 q-mr-md"
v-if=
"dataList.priceList.length>0"
>
CNY
{{
moneyFormat(dataList.priceList[0].originalB2CPrice, 0)
}}
</span
<span
class=
"product-price text-h6 q-mr-md"
v-if=
"dataList.priceList.length > 0"
>
CNY
{{ moneyFormat(dataList.priceList[0].originalB2CPrice, 0)
}}
</span
>
<q-btn
color=
"primary"
...
...
@@ -370,9 +329,7 @@
v-if=
"showOrderPreview"
>
<div
class=
"q-pa-md bg-grey-2 row items-center rounded-borders"
>
<div
class=
"text-subtitle2 text-weight-bold q-mr-xl"
>
關於此方案
</div>
<div
class=
"text-subtitle2 text-weight-bold q-mr-xl"
>
關於此方案
</div>
<q-chip
class=
"transparent q-mr-xl no-padding"
square
...
...
@@ -412,28 +369,37 @@
<div
v-if=
"dataList"
style=
"margin-left: auto; margin-right: auto"
:style=
"{
'width': $q.platform.is.desktop?'1200px':'100%'
}"
:style=
"{
width: $q.platform.is.desktop ? '1200px' : '100%'
}"
class=
"q-mt-xl row"
:class=
"{ 'q-px-md': $q.screen.width < 1220 && $q.screen.width > 760 }"
>
<!-- col q-ml-xl position-relative -->
<div
class=
"absolute"
style=
"z-index: 999;left: -150px;"
:style=
"{'top':currentHeight>navs[1].top?(currentHeight+100)+'px':(currentHeight+200)+'px'}"
v-if=
"$q.platform.is.desktop&&
currentHeight>navs[1].top-400
&¤tHeight<navs[2].top&&dataList.dayList.length>3
class=
"absolute"
style=
"z-index: 999; left: -150px"
:style=
"{
top:
currentHeight > navs[1].top
? currentHeight + 100 + 'px'
: currentHeight + 200 + 'px',
}"
v-if=
"
$q.platform.is.desktop &&
currentHeight > navs[1].top - 400 &&
currentHeight < navs[2].top &&
dataList.dayList.length > 3
"
>
<!-- style="position: sticky; top: 100px" -->
<div
v-if=
"true"
>
<div
v-for=
"(x, i) in days"
:key=
"i"
>
<div
v-if=
"moreDays==2&&i==0"
style=
"text-align: center;margin-bottom: 21px;cursor: pointer;"
@
click=
"goScrollHandler(x.top + 50),moreDays=1"
>
<div
v-if=
"moreDays == 2 && i == 0"
style=
"text-align: center; margin-bottom: 21px; cursor: pointer"
@
click=
"goScrollHandler(x.top + 50), (moreDays = 1)"
>
...
</div>
<div
v-if=
"(
moreDays&&moreDays==1||!moreDays)&&i<
8"
v-if=
"(
(moreDays && moreDays == 1) || !moreDays) && i <
8"
class=
"trip-module text-subtitle2 cursor-pointer q-mb-lg"
@
click=
"goScrollHandler(x.top + 50)"
:class=
"{
...
...
@@ -446,7 +412,7 @@
</div>
<div
v-if=
"moreDays
&&moreDays==2&&i>=
8"
v-if=
"moreDays
&& moreDays == 2 && i >=
8"
class=
"trip-module text-subtitle2 cursor-pointer q-mb-lg"
@
click=
"goScrollHandler(x.top + 50)"
:class=
"{
...
...
@@ -457,17 +423,20 @@
>
{{ x.display }}
</div>
<div
v-if=
"(!moreDays||moreDays==1)&&days.length>8&&i==8"
style=
"text-align: center;cursor: pointer;"
@
click=
"goScrollHandler(x.top + 50),moreDays=2"
>
<div
v-if=
"(!moreDays || moreDays == 1) && days.length > 8 && i == 8"
style=
"text-align: center; cursor: pointer"
@
click=
"goScrollHandler(x.top + 50), (moreDays = 2)"
>
...
</div>
</div>
</div>
</div>
<div
style=
"width: 100%
;
"
style=
"width: 100%"
:class=
"{
'col'
: $q.platform.is.desktop,
col
: $q.platform.is.desktop,
col: $q.platform.is.mobile,
}"
>
...
...
@@ -482,14 +451,21 @@
行程特色
</div>
<div>
<div
class=
"q-pb-xl"
v-if=
"tripImages&&tripImages.length>0"
ref=
"diyContext"
>
<div
v-for=
"(x,i) in tripImages"
>
<img
v-if=
"dataList.teamType!=2"
class=
"block"
:src=
"x.header"
width=
"100%"
>
<img
class=
"block"
:src=
"x.page"
style=
"width: 100%"
>
<div
v-if=
"dataList.teamType!=2"
class=
"tripImages-footer"
>
<img
class=
"block"
:src=
"x.footer"
style=
"width: 100%"
>
<div
class=
"q-pb-xl"
v-if=
"tripImages && tripImages.length > 0"
ref=
"diyContext"
>
<div
v-for=
"(x, i) in tripImages"
>
<img
v-if=
"dataList.teamType != 2"
class=
"block"
:src=
"x.header"
width=
"100%"
/>
<img
class=
"block"
:src=
"x.page"
style=
"width: 100%"
/>
<div
v-if=
"dataList.teamType != 2"
class=
"tripImages-footer"
>
<img
class=
"block"
:src=
"x.footer"
style=
"width: 100%"
/>
</div>
</div>
</div>
...
...
@@ -504,7 +480,10 @@
ref=
"diyContext"
:style=
"{ zoom: zoomDiyContext }"
v-html=
"dataList.feature.featureHtml"
v-else-if=
"dataList.feature.featureHtml != '' && (!tripImages || tripImages.length==0)"
v-else-if=
"
dataList.feature.featureHtml != '' &&
(!tripImages || tripImages.length == 0)
"
></div>
</div>
...
...
@@ -522,49 +501,34 @@
v-if=
"dataList"
:trip=
"dataList"
class=
"q-pb-xl"
:class=
"{'q-px-md':$q.platform.is.mobile
}"
:class=
"{ 'q-px-md': $q.platform.is.mobile
}"
></smaple>
<
template
v-if=
"detailsImageList&&detailsImageList.length>0"
>
<
template
v-if=
"detailsImageList && detailsImageList.length > 0"
>
<div
v-for=
"(x, i) in detailsImageList"
:id=
"`days_$
{i}`">
<div
v-for=
"(x,i) in detailsImageList"
:id=
"`days_$
{i}`">
<div
class=
"tripImages-footer"
v-if=
"!dataList.tripColor"
style=
"padding: 20px 0;"
>
</div>
<!--
<img
v-if=
"dataList.teamType!=2"
class=
"block"
:src=
"x.header"
width=
"100%"
>
-->
<img
class=
"block"
:src=
"x.page"
style=
"width: 100%"
>
<div
class=
"tripImages-footer"
>
<!--
<img
v-if=
"dataList.tripColor"
class=
"block"
:src=
"x.footer"
style=
"width: 100%"
>
-->
</div>
class=
"tripImages-footer"
v-if=
"!dataList.tripColor"
style=
"padding: 20px 0"
></div>
<img
class=
"block"
:src=
"x.page"
style=
"width: 100%"
/>
<div
class=
"tripImages-footer"
></div>
</div>
</
template
>
<
template
v-else
>
<template
v-if=
"dataList.dayList.length
<
=
3
"
>
<template
v-if=
"dataList.dayList.length
<
=
3
"
>
<trip
:trip=
"dataList"
@
change=
"changeTripShowHandler"
></trip>
</
template
>
<
template
v-if=
"dataList.dayList.length>3"
>
<block
v-if=
"false"
:currentHeightDay=
"currentHeight"
:days=
"days"
:tripList=
"dayList"
:isDirect=
"isDirect"
:clickDate=
"clickDate"
></block>
</
template
>
</template>
<!--
<template
v-if="
(dataList.priceList.length > 0 &&
dataList.priceList &&
dataList.priceList[0].teamType == 2) ||
(dataList.currentPrice && dataList.currentPrice.teamType == 2)
"
>
<trip :trip="dataList" @change="changeTripShowHandler"></trip>
</template>
<template v-else>
<
template
v-if=
"dataList.dayList.length > 3"
>
<block
v-if=
"false"
:currentHeightDay=
"currentHeight"
:days=
"days"
:tripList=
"dayList"
:isDirect=
"isDirect"
:clickDate=
"clickDate"
></block>
</template> -->
</
template
>
</template>
</div>
<div
...
...
@@ -622,16 +586,19 @@
'q-mx-md': $q.screen.width < 1220 && $q.platform.is.mobile,
}"
>
<div
v-html=
"
dataList.feature.shopRemark
? dataList.feature.shopRemark
: '暫無購買說明'
"
></div>
<div
v-html=
"
dataList.feature.shopRemark ? dataList.feature.shopRemark : '暫無購買說明'
"
></div>
<div
class=
"q-mb-lg text-weight-bold fz18"
>
購物安排
</div>
<q-table
:data=
"dataList.shopList"
:columns=
"columns"
<q-table
:data=
"dataList.shopList"
:columns=
"columns"
bordered
class=
"my-sticky-header-table no-shadow"
:hide-bottom=
"true"
>
:hide-bottom=
"true"
>
<
template
v-slot:header
>
<q-tr
class=
"bg-orange-1"
>
<q-th
v-for=
"(item, i) in columns"
:key=
"i"
class=
"text-left"
>
...
...
@@ -692,11 +659,11 @@
}"
>
<div
class=
"text-weight-bold fz18 q-mb-md"
>
簽字須知
</div>
<div
v-html=
"
dataList.feature.visaRemark
? dataList.feature.visaRemark
: '暫無簽字須知'
"
></div>
<div
v-html=
"
dataList.feature.visaRemark ? dataList.feature.visaRemark : '暫無簽字須知'
"
></div>
</div>
<div
class=
"text-h5 text-weight-bold text-left q-mt-xl"
...
...
@@ -710,16 +677,11 @@
<div
class=
"q-mt-lg trip-text bg-white q-pa-md rounded-borders q-mb-xl"
style=
"border: 1px dashed var(--q-color-info)"
v-html=
"
dataList.feature.warmTip
? dataList.feature.warmTip
: '暂无溫馨提示'
"
v-html=
"dataList.feature.warmTip ? dataList.feature.warmTip : '暂无溫馨提示'"
:class=
"{
'q-mx-md': $q.screen.width < 1220 && $q.platform.is.mobile,
}"
>
</div>
></div>
<!-- <div
class="text-h5 text-weight-bold text-left q-mt-xl"
ref="cancelTips"
...
...
@@ -766,14 +728,19 @@
</div>
</div> -->
</div>
<
template
v-if=
"$q.platform.is.desktop&¤tHeight>130
&&$refs.journeyLookOut.getBoundingClientRect().top+currentHeight-280>currentHeight"
>
<!--
<div
class=
"col-1"
></div>
-->
<!-- col q-ml-xl position-relative -->
<
template
v-if=
"
$q.platform.is.desktop &&
currentHeight > 130 &&
$refs.journeyLookOut.getBoundingClientRect().top + currentHeight - 280 >
currentHeight
"
>
<div
class=
"absolute"
style=
"z-index: 999;right: -150px;"
:style=
"
{'top':currentHeight
<1000
?'
1000px
'
:
(
currentHeight
+
100
)+'
px
'}"
>
<!-- style="position: sticky; top: 100px" -->
class=
"absolute"
style=
"z-index: 999; right: -150px"
:style=
"
{ top: currentHeight
<
1000
?
'
1000px
'
:
currentHeight
+
100
+
'
px
'
}"
>
<div>
<div
class=
"text-subtitle2 text-grey-6 cursor-pointer q-mb-md"
...
...
@@ -818,7 +785,8 @@ export default {
props
:
[],
data
()
{
return
{
columns
:
[{
columns
:
[
{
name
:
"cityName"
,
required
:
true
,
label
:
"城市"
,
...
...
@@ -845,7 +813,7 @@ export default {
configId
:
0
,
cityId
:
0
,
preview
:
0
,
tcid
:
''
,
tcid
:
""
,
teamType
:
0
,
isGetPriceFlight
:
true
,
pType
:
1
,
//类型 1 来源B2C
...
...
@@ -945,8 +913,8 @@ export default {
priceListHeight
:
0
,
stickyHeight
:
0
,
zoomDiyContext
:
1
,
detailsImageList
:[],
tripImages
:[],
detailsImageList
:
[],
tripImages
:
[],
moreDays
:
0
,
};
},
...
...
@@ -959,26 +927,26 @@ export default {
Trip
,
block
,
Flight
,
NoneData
NoneData
,
},
watch
:
{
days
:
{
handler
:
function
(
val
,
oldval
)
{
this
.
days
=
val
;
let
that
=
this
this
.
$nextTick
(()
=>
{
try
{
that
.
days
.
forEach
((
x
,
i
)
=>
{
var
object
=
document
.
getElementById
(
`days_
${
i
}
`
);
x
.
top
=
object
.
getBoundingClientRect
().
top
+
60
})
let
that
=
this
;
this
.
$nextTick
(()
=>
{
try
{
that
.
days
.
forEach
((
x
,
i
)
=>
{
var
object
=
document
.
getElementById
(
`days_
${
i
}
`
);
x
.
top
=
object
.
getBoundingClientRect
().
top
+
60
;
});
}
catch
(
error
)
{
console
.
log
(
'----异常'
)
console
.
log
(
"----异常"
);
}
// setTimeout(()=>{
// that.getTopNum(JSON.stringify(that.days))
// },1000)
})
})
;
},
immediate
:
true
,
deep
:
true
,
...
...
@@ -989,8 +957,7 @@ export default {
if
(
x
.
top
&&
this
.
currentHeight
>=
x
.
top
&&
(
i
==
this
.
navs
.
length
-
1
||
this
.
currentHeight
<
this
.
navs
[
i
+
1
].
top
)
(
i
==
this
.
navs
.
length
-
1
||
this
.
currentHeight
<
this
.
navs
[
i
+
1
].
top
)
)
{
if
(
this
.
tab
!=
x
.
display
)
{
this
.
tab
=
x
.
display
;
...
...
@@ -1026,43 +993,44 @@ export default {
// this.getCarData();
},
methods
:
{
getTripFeatureImageHandler
(
configId
){
this
.
$axios
.
get
(
"http://upload.oytour.com/Home/GetTripImage?configId="
+
configId
).
then
(
r
=>
{
console
.
log
(
r
.
data
,
'r.data.data.id'
)
if
(
r
.
data
.
OtherFile
){
this
.
tripImages
=
[]
let
OtherFile
=
r
.
data
.
OtherFile
let
length
=
OtherFile
.
length
let
header
=
OtherFile
[
length
-
1
]
let
footer
=
OtherFile
[
length
-
2
]
if
(
OtherFile
[
0
].
indexOf
(
'footer'
)
!=-
1
){
header
=
OtherFile
[
1
]
footer
=
OtherFile
[
0
]
getTripFeatureImageHandler
(
configId
)
{
this
.
$axios
.
get
(
"http://upload.oytour.com/Home/GetTripImage?configId="
+
configId
)
.
then
((
r
)
=>
{
console
.
log
(
r
.
data
,
"r.data.data.id"
);
if
(
r
.
data
.
OtherFile
)
{
this
.
tripImages
=
[];
let
OtherFile
=
r
.
data
.
OtherFile
;
let
length
=
OtherFile
.
length
;
let
header
=
OtherFile
[
length
-
1
];
let
footer
=
OtherFile
[
length
-
2
];
if
(
OtherFile
[
0
].
indexOf
(
"footer"
)
!=
-
1
)
{
header
=
OtherFile
[
1
];
footer
=
OtherFile
[
0
];
}
OtherFile
.
forEach
((
x
,
i
)
=>
{
OtherFile
.
forEach
((
x
,
i
)
=>
{
let
obj
=
{
header
:
header
,
page
:
x
,
footer
:
footer
,
};
if
(
OtherFile
[
0
].
indexOf
(
"footer"
)
!=
-
1
)
{
if
(
i
>
1
)
{
this
.
tripImages
.
push
(
obj
);
}
if
(
OtherFile
[
0
].
indexOf
(
'footer'
)
!=-
1
){
if
(
i
>
1
){
this
.
tripImages
.
push
(
obj
)
}
}
else
{
if
(
i
<
length
-
2
){
this
.
tripImages
.
push
(
obj
)
}
else
{
if
(
i
<
length
-
2
)
{
this
.
tripImages
.
push
(
obj
);
}
}
})
});
this
.
$forceUpdate
();
}
})
});
},
changeShowOrderPreviewHandler
()
{
this
.
showOrderPreview
=
!
this
.
showOrderPreview
;
if
(
!
this
.
showOrderPreview
)
{
// this.currentPrice=null
if
(
this
.
currentPrice
)
{
this
.
currentPrice
.
isSupportChildren
=
null
;
this
.
currentPrice
.
unionCityList
=
null
;
...
...
@@ -1078,20 +1046,12 @@ export default {
changeTripShowHandler
()
{
this
.
$nextTick
(()
=>
{
this
.
navs
.
forEach
((
x
)
=>
{
x
.
top
=
this
.
$refs
[
x
.
val
].
getBoundingClientRect
().
top
+
this
.
currentHeight
-
60
;
x
.
top
=
this
.
$refs
[
x
.
val
].
getBoundingClientRect
().
top
+
this
.
currentHeight
-
60
;
});
});
},
handleScroll
(
e
)
{
let
temp
=
this
.
getScroll
().
top
;
// if(temp-this.currentHeight>0){
// this.scrollDirection='down'
// }else{
// this.scrollDirection='up'
// }
this
.
stickyHeight
=
document
.
querySelector
(
".q-header--hidden"
)
?
"translateY(0px)"
:
"translateY(45px)"
;
...
...
@@ -1144,11 +1104,7 @@ export default {
},
slideHandler
(
e
)
{
this
.
options
.
currentPage
=
e
.
currentPage
;
if
(
e
.
currentPage
!=
0
&&
this
.
$refs
.
video
&&
this
.
$refs
.
video
.
isPlaying
)
{
if
(
e
.
currentPage
!=
0
&&
this
.
$refs
.
video
&&
this
.
$refs
.
video
.
isPlaying
)
{
this
.
$refs
.
video
.
pause
();
}
},
...
...
@@ -1212,39 +1168,38 @@ export default {
},
getData
()
{
this
.
$q
.
loading
.
show
();
let
that
=
this
console
.
log
(
this
.
$q
.
loading
)
let
that
=
this
;
this
.
apipost
(
"b2b_get_Get2024B2BTravelInfoV1"
,
this
.
msg
,
(
r
)
=>
{
try
{
if
(
r
.
data
.
resultCode
==
1
&&
r
.
data
.
data
.
id
>
0
)
{
this
.
tripImages
=
[]
this
.
detailsImageList
=
[]
let
header
=
r
.
data
.
data
.
feature
.
headerImage
let
footer
=
r
.
data
.
data
.
feature
.
footerImage
if
(
r
.
data
.
data
.
feature
.
tripImageList
.
length
>
0
)
{
let
OtherFile
=
r
.
data
.
data
.
feature
.
tripImageList
OtherFile
.
forEach
((
x
,
i
)
=>
{
if
(
r
.
data
.
resultCode
==
1
&&
r
.
data
.
data
.
id
>
0
)
{
this
.
tripImages
=
[]
;
this
.
detailsImageList
=
[]
;
let
header
=
r
.
data
.
data
.
feature
.
headerImage
;
let
footer
=
r
.
data
.
data
.
feature
.
footerImage
;
if
(
r
.
data
.
data
.
feature
.
tripImageList
.
length
>
0
)
{
let
OtherFile
=
r
.
data
.
data
.
feature
.
tripImageList
;
OtherFile
.
forEach
((
x
,
i
)
=>
{
let
obj
=
{
header
:
header
,
page
:
x
,
footer
:
footer
,
};
this
.
tripImages
.
push
(
obj
);
});
}
this
.
tripImages
.
push
(
obj
)
})
}
if
(
r
.
data
.
data
.
feature
.
detailsImageList
.
length
>
0
){
let
OtherFile
=
r
.
data
.
data
.
feature
.
detailsImageList
OtherFile
.
forEach
((
x
,
i
)
=>
{
if
(
r
.
data
.
data
.
feature
.
detailsImageList
.
length
>
0
)
{
let
OtherFile
=
r
.
data
.
data
.
feature
.
detailsImageList
;
OtherFile
.
forEach
((
x
,
i
)
=>
{
let
obj
=
{
header
:
header
,
page
:
x
,
footer
:
footer
,
}
this
.
detailsImageList
.
push
(
obj
)
})
}
;
this
.
detailsImageList
.
push
(
obj
)
;
})
;
}
// tripImageList detailsImageList headerImage footerImage
// this.getTripFeatureImageHandler(r.data.data.id)
...
...
@@ -1284,8 +1239,7 @@ export default {
}
this
.
$nextTick
(()
=>
{
if
(
that
.
dataList
.
feature
.
featureHtml
!=
""
)
{
let
tw
=
parseFloat
(
let
tw
=
parseFloat
(
that
.
$refs
.
diyContext
.
getBoundingClientRect
().
width
);
// / 1123.0
...
...
@@ -1296,14 +1250,13 @@ export default {
div
.
style
.
zoom
=
div
.
offsetWidth
>
1000
?
0.999
:
document
.
documentElement
.
clientWidth
;
/// 1123.0
:
document
.
documentElement
.
clientWidth
;
/// 1123.0
}
else
{
div
.
style
.
zoom
=
1
;
}
}
that
.
zoomDiyContext
=
tw
>
1
?
1
:
tw
.
toFixed
(
2
);
}
setTimeout
(()
=>
{
this
.
navs
.
forEach
((
x
)
=>
{
...
...
@@ -1311,13 +1264,13 @@ export default {
// this.$refs[x.val].getBoundingClientRect().top +
// this.currentHeight -
// 60;
x
.
top
=
this
.
$refs
[
x
.
val
].
getBoundingClientRect
().
top
x
.
top
=
this
.
$refs
[
x
.
val
].
getBoundingClientRect
().
top
;
});
// this.priceListHeight =
// this.$refs.pricelist.getBoundingClientRect().top +
// this.currentHeight -
// 60;
this
.
priceListHeight
=
this
.
$refs
.
pricelist
.
getBoundingClientRect
().
top
this
.
priceListHeight
=
this
.
$refs
.
pricelist
.
getBoundingClientRect
().
top
;
this
.
days
=
[];
this
.
dayList
.
forEach
((
x
)
=>
{
let
dayListObj
=
{
...
...
@@ -1329,10 +1282,10 @@ export default {
this
.
days
.
push
(
dayListObj
);
});
if
(
this
.
days
.
length
>
8
)
{
this
.
moreDays
=
0
}
else
{
this
.
moreDays
=
1
if
(
this
.
days
.
length
>
8
)
{
this
.
moreDays
=
0
;
}
else
{
this
.
moreDays
=
1
;
}
},
1000
);
...
...
@@ -1340,7 +1293,6 @@ export default {
document
.
querySelector
(
"#scrollId .q-page-container"
)
.
addEventListener
(
"scroll"
,
this
.
handleScrollDay
);
}
catch
(
error
)
{
// console.log(document.querySelector('#scrollId .q-page-container'))
// console.log('异常信息', error)
...
...
@@ -1350,7 +1302,7 @@ export default {
}
catch
(
error
)
{}
this
.
$q
.
loading
.
hide
();
},
e
=>
{
(
e
)
=>
{
this
.
$q
.
loading
.
hide
();
}
);
...
...
@@ -1365,7 +1317,6 @@ export default {
this
.
currentPrice
.
originalB2CPrice
+=
unionCity
.
goFlight
.
addPrice
;
}
}
console
.
log
(
this
.
$refs
);
if
(
this
.
$q
.
platform
.
is
.
desktop
)
this
.
$refs
.
calendar
.
changePriceHandler
(
this
.
currentPrice
.
startDate
,
...
...
@@ -1415,9 +1366,8 @@ export default {
this
.
$nextTick
(()
=>
{
if
(
this
.
dataList
.
feature
.
featureHtml
!=
""
)
{
let
tw
=
parseFloat
(
this
.
$refs
.
diyContext
.
getBoundingClientRect
().
width
)
/
1123.0
;
parseFloat
(
this
.
$refs
.
diyContext
.
getBoundingClientRect
().
width
)
/
1123.0
;
let
divArr
=
document
.
querySelectorAll
(
"#setZoom>div"
);
for
(
let
i
=
0
;
i
<
divArr
.
length
;
i
++
)
{
...
...
@@ -1467,7 +1417,7 @@ export default {
}
});
}
else
{
this
.
$message
.
error
(
r
.
data
.
message
)
this
.
$message
.
error
(
r
.
data
.
message
)
;
}
this
.
$q
.
loading
.
hide
();
},
...
...
@@ -1475,8 +1425,7 @@ export default {
);
},
menu
()
{
this
.
scroll
=
document
.
documentElement
.
scrollTop
||
document
.
body
.
scrollTop
;
this
.
scroll
=
document
.
documentElement
.
scrollTop
||
document
.
body
.
scrollTop
;
if
(
this
.
scroll
>
300
)
{
this
.
isShowNav
=
true
;
}
else
{
...
...
@@ -1495,7 +1444,7 @@ export default {
.line-feature
*
{
line-height
:
normal
!important
;
}
.line-feature
.draggable
{
.line-feature
.draggable
{
position
:
absolute
;
}
.slider-item
{
...
...
@@ -1570,11 +1519,11 @@ export default {
#setZoom
>
div
{
zoom
:
calc
(
100
/
1000
);
}
.large-feature
img
{
width
:
100%
!important
.large-feature
img
{
width
:
100%
!important
;
}
.tripImages-footer
{
background
:
url(
'../assets/img/trip/otherBjThree.jpg'
)
repeat
;
.tripImages-footer
{
background
:
url(
"../assets/img/trip/otherBjThree.jpg"
)
repeat
;
padding
:
115px
0
32px
0
;
}
</
style
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment