|
@ -2,32 +2,16 @@ |
|
|
<!-- 全域旅游 --> |
|
|
<!-- 全域旅游 --> |
|
|
<div class="eb-container" ref="appRef"> |
|
|
<div class="eb-container" ref="appRef"> |
|
|
<MainTitle class="title" :title="title"></MainTitle> |
|
|
<MainTitle class="title" :title="title"></MainTitle> |
|
|
<gis-map |
|
|
<gis-map ref="gisMapRef" class="gismap" pointType="全域旅游" :point-list="dataList" @currentPoint="currentPointFn" |
|
|
ref="gisMapRef" |
|
|
:lngLat="lngLat" list-item-key="name"> |
|
|
class="gismap" |
|
|
|
|
|
|
|
|
|
|
|
pointType="全域旅游" |
|
|
|
|
|
:point-list="dataList" |
|
|
|
|
|
@currentPoint="currentPointFn" |
|
|
|
|
|
:lngLat="lngLat" |
|
|
|
|
|
list-item-key="name" |
|
|
|
|
|
> |
|
|
|
|
|
<template v-slot:content> |
|
|
<template v-slot:content> |
|
|
<div class="center-window"> |
|
|
<div class="center-window"> |
|
|
<div |
|
|
<div class="top-title" v-for="(item, index) in iconList" @click="changeType(item, index)"> |
|
|
class="top-title" |
|
|
<img :src="item.icon" /> |
|
|
v-for="(item, index) in iconList" |
|
|
|
|
|
@click="changeType(item, index)" |
|
|
|
|
|
> |
|
|
|
|
|
<img :src="item.icon"/> |
|
|
|
|
|
<div class="text"> |
|
|
<div class="text"> |
|
|
<p class="text-name">{{ item.label }}</p> |
|
|
<p class="text-name">{{ item.label }}</p> |
|
|
<p class="text-type"> |
|
|
<p class="text-type"> |
|
|
<CountTo |
|
|
<CountTo :startVal="0" :endVal="item.count" :duration="2000" /> |
|
|
:startVal="0" |
|
|
|
|
|
:endVal="item.count" |
|
|
|
|
|
:duration="2000" |
|
|
|
|
|
/> |
|
|
|
|
|
</p> |
|
|
</p> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
@ -38,16 +22,9 @@ |
|
|
</div> |
|
|
</div> |
|
|
<div class="content-info"> |
|
|
<div class="content-info"> |
|
|
<div class="content-inof-list"> |
|
|
<div class="content-inof-list"> |
|
|
<div |
|
|
<div class="content-info-item" v-for="(item, index) in travleList" :key="index" |
|
|
class="content-info-item" |
|
|
@click="selectTravelInfoById(item.id, item)"> |
|
|
v-for="(item, index) in travleList" |
|
|
<div class="content-info-item-title" style="font-size: 20px; color: #fff"> |
|
|
:key="index" |
|
|
|
|
|
@click="selectTravelInfoById(item.id, item)" |
|
|
|
|
|
> |
|
|
|
|
|
<div |
|
|
|
|
|
class="content-info-item-title" |
|
|
|
|
|
style="font-size: 20px; color: #fff" |
|
|
|
|
|
> |
|
|
|
|
|
{{ item.name }} |
|
|
{{ item.name }} |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
@ -61,77 +38,55 @@ |
|
|
<div class="content-info"> |
|
|
<div class="content-info"> |
|
|
<!-- title --> |
|
|
<!-- title --> |
|
|
<div class="content-info-title"> |
|
|
<div class="content-info-title"> |
|
|
<span |
|
|
<span style=" |
|
|
style=" |
|
|
|
|
|
font-size: 24px; |
|
|
font-size: 24px; |
|
|
color: #fff; |
|
|
color: #fff; |
|
|
font-weight: bold; |
|
|
font-weight: bold; |
|
|
" |
|
|
">{{ detailInfo.name }}</span> |
|
|
>{{ detailInfo.name }}</span |
|
|
|
|
|
> |
|
|
|
|
|
<span style="font-size: 18px; color: #c9c9c9">{{ |
|
|
<span style="font-size: 18px; color: #c9c9c9">{{ |
|
|
typeList[detailInfo.type] |
|
|
typeList[detailInfo.type] |
|
|
}}</span> |
|
|
}}</span> |
|
|
</div> |
|
|
</div> |
|
|
<!-- content --> |
|
|
<!-- content --> |
|
|
<div |
|
|
<div class="content-info-content" style="margin-top: 20px"> |
|
|
class="content-info-content" |
|
|
<span style="font-size: 24px; color: #fff">基础信息</span> |
|
|
style="margin-top: 20px" |
|
|
|
|
|
> |
|
|
|
|
|
<span style="font-size: 24px; color: #fff" |
|
|
|
|
|
>基础信息</span |
|
|
|
|
|
> |
|
|
|
|
|
<div style="margin-top: 10px" v-if="detailInfo.address"> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.address"> |
|
|
<span style="font-size: 18px; color: #c9c9c9" |
|
|
<span style="font-size: 18px; color: #c9c9c9">地址: |
|
|
>地址: |
|
|
|
|
|
</span> |
|
|
</span> |
|
|
<span style="font-size: 18px; color: #fff">{{ |
|
|
<span style="font-size: 18px; color: #fff">{{ |
|
|
detailInfo.address |
|
|
detailInfo.address |
|
|
}}</span> |
|
|
}}</span> |
|
|
</div> |
|
|
</div> |
|
|
<!-- 工作时间 --> |
|
|
<!-- 工作时间 --> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.openHours"> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.openHours"> |
|
|
<span style="font-size: 18px; color: #c9c9c9" |
|
|
<span style="font-size: 18px; color: #c9c9c9">工作时间: |
|
|
>工作时间: |
|
|
|
|
|
</span> |
|
|
</span> |
|
|
<span style="font-size: 18px; color: #fff">{{ |
|
|
<span style="font-size: 18px; color: #fff">{{ |
|
|
detailInfo.openHours |
|
|
detailInfo.openHours |
|
|
}}</span> |
|
|
}}</span> |
|
|
</div> |
|
|
</div> |
|
|
<!-- 简介 --> |
|
|
<!-- 简介 --> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.remark"> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.remark"> |
|
|
<span style="font-size: 18px; color: #c9c9c9" |
|
|
<span style="font-size: 18px; color: #c9c9c9">简介: |
|
|
>简介: |
|
|
|
|
|
</span> |
|
|
</span> |
|
|
<span style="font-size: 18px; color: #fff">{{ |
|
|
<span style="font-size: 18px; color: #fff">{{ |
|
|
detailInfo.remark |
|
|
detailInfo.remark |
|
|
}}</span> |
|
|
}}</span> |
|
|
</div> |
|
|
</div> |
|
|
<!-- 图片 --> |
|
|
<!-- 图片 --> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.coverImage"> |
|
|
<div style="margin-top: 10px" v-if="detailInfo.coverImage"> |
|
|
<span style="font-size: 18px; color: #c9c9c9" |
|
|
<span style="font-size: 18px; color: #c9c9c9">图片: |
|
|
>图片: |
|
|
|
|
|
</span> |
|
|
</span> |
|
|
<img |
|
|
<img :src="detailInfo.coverImage" alt="" style="width: 100%; height: 200px" /> |
|
|
:src="detailInfo.coverImage" |
|
|
|
|
|
alt="" |
|
|
|
|
|
style="width: 100%; height: 200px" |
|
|
|
|
|
/> |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
<div |
|
|
<div style=" |
|
|
style=" |
|
|
|
|
|
display: flex; |
|
|
display: flex; |
|
|
align-items: center; |
|
|
align-items: center; |
|
|
margin-top: 20px; |
|
|
margin-top: 20px; |
|
|
" |
|
|
"> |
|
|
> |
|
|
<Button type="text" class="text-button" @click=" |
|
|
<Button |
|
|
openLineOrPlayAudio(detailInfo.type) |
|
|
type="text" |
|
|
"> |
|
|
class="text-button" |
|
|
|
|
|
@click=" |
|
|
|
|
|
openLineOrPlayAudio(detailInfo.type) |
|
|
|
|
|
" |
|
|
|
|
|
> |
|
|
|
|
|
{{ |
|
|
{{ |
|
|
detailInfo.type == 4 |
|
|
detailInfo.type == 4 |
|
|
? "播放音频" |
|
|
? "播放音频" |
|
@ -141,13 +96,8 @@ |
|
|
}} |
|
|
}} |
|
|
</Button> |
|
|
</Button> |
|
|
<!-- 音频播放 --> |
|
|
<!-- 音频播放 --> |
|
|
<audio |
|
|
<audio ref="audioRef" class="audio-controls" v-if="detailInfo.type == 4" |
|
|
ref="audioRef" |
|
|
:src="detailInfo.audioList" controls></audio> |
|
|
class="audio-controls" |
|
|
|
|
|
v-if="detailInfo.type == 4" |
|
|
|
|
|
:src="detailInfo.audioList" |
|
|
|
|
|
controls |
|
|
|
|
|
></audio> |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
@ -155,20 +105,13 @@ |
|
|
</template> |
|
|
</template> |
|
|
</gis-map> |
|
|
</gis-map> |
|
|
<div class="page-bottom-bg"></div> |
|
|
<div class="page-bottom-bg"></div> |
|
|
<div class="page-left-bg"></div> |
|
|
<div class="page-left-bg"></div> |
|
|
<div class="page-right-bg"></div> |
|
|
<div class="page-right-bg"></div> |
|
|
|
|
|
|
|
|
<commonModal v-model="lineVisible" title="相关路线" width="600"> |
|
|
<commonModal v-model="lineVisible" title="相关路线" width="600"> |
|
|
<div class="line-box"> |
|
|
<div class="line-box"> |
|
|
<div |
|
|
<div class="line-item" v-for="(item, index) in lineList" @click="openLine(item)" :key="index"> |
|
|
class="line-item" |
|
|
<span class="line-title">线路名称:{{ item.lineName }}</span> |
|
|
v-for="(item, index) in lineList" |
|
|
|
|
|
@click="openLine(item)" |
|
|
|
|
|
:key="index" |
|
|
|
|
|
> |
|
|
|
|
|
<span class="line-title" |
|
|
|
|
|
>线路名称:{{ item.lineName }}</span |
|
|
|
|
|
> |
|
|
|
|
|
<div class="line-content"> |
|
|
<div class="line-content"> |
|
|
<span>线路途经:{{ item.lineText }}</span> |
|
|
<span>线路途经:{{ item.lineText }}</span> |
|
|
</div> |
|
|
</div> |
|
@ -179,14 +122,14 @@ |
|
|
</template> |
|
|
</template> |
|
|
|
|
|
|
|
|
<script> |
|
|
<script> |
|
|
import {useIndex} from "../../utils/utilsDramAdmin"; |
|
|
import { useIndex } from "../../utils/utilsDramAdmin"; |
|
|
import MainTitle from "./components/MainTitle.vue"; |
|
|
import MainTitle from "./components/MainTitle.vue"; |
|
|
import gisMap from "./components/gisMapOfCounty.vue"; |
|
|
import gisMap from "./components/gisMapOfCounty.vue"; |
|
|
import commonModal from "@/views/common-components/common-modal.vue"; |
|
|
import commonModal from "@/views/common-components/common-modal.vue"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: "GlobalTravel", |
|
|
name: "GlobalTravel", |
|
|
components: {MainTitle, gisMap, commonModal}, |
|
|
components: { MainTitle, gisMap, commonModal }, |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
title: "全域旅游", |
|
|
title: "全域旅游", |
|
@ -235,14 +178,14 @@ export default { |
|
|
type: "", |
|
|
type: "", |
|
|
iconList: [ |
|
|
iconList: [ |
|
|
// 1、酒店 2、景区 3、饭店 4、讲解 5、服务区 6、设备设施 |
|
|
// 1、酒店 2、景区 3、饭店 4、讲解 5、服务区 6、设备设施 |
|
|
{icon: require("@/assets/mapIcon/jd.png"), label: "住宿", count: 0, type: "1"}, |
|
|
{ icon: require("@/assets/mapIcon/jd.png"), label: "住宿", count: 0, type: "1" }, |
|
|
{icon: require("@/assets/mapIcon/jq.png"), label: "景点", count: 0, type: "2"}, |
|
|
{ icon: require("@/assets/mapIcon/jq.png"), label: "景点", count: 0, type: "2" }, |
|
|
{icon: require("@/assets/mapIcon/fd.png"), label: "美食", count: 0, type: "3"}, |
|
|
{ icon: require("@/assets/mapIcon/fd.png"), label: "美食", count: 0, type: "3" }, |
|
|
{icon: require("@/assets/mapIcon/jj.png"), label: "讲解", count: 0, type: "4"}, |
|
|
{ icon: require("@/assets/mapIcon/jj.png"), label: "讲解", count: 0, type: "4" }, |
|
|
{icon: require("@/assets/mapIcon/sd.png"), label: "商店", count: 0, type: "5"}, |
|
|
{ icon: require("@/assets/mapIcon/sd.png"), label: "商店", count: 0, type: "5" }, |
|
|
{icon: require("@/assets/mapIcon/wsj.png"), label: "卫生间", count: 0, type: "6"}, |
|
|
{ icon: require("@/assets/mapIcon/wsj.png"), label: "卫生间", count: 0, type: "6" }, |
|
|
{icon: require("@/assets/mapIcon/fwq.png"), label: "停车场", count: 0, type: "7"}, |
|
|
{ icon: require("@/assets/mapIcon/fwq.png"), label: "停车场", count: 0, type: "7" }, |
|
|
{icon: require("@/assets/mapIcon/ykzx.png"), label: "游客服务", count: 0, type: "8"}, |
|
|
{ icon: require("@/assets/mapIcon/ykzx.png"), label: "游客服务", count: 0, type: "8" }, |
|
|
], |
|
|
], |
|
|
travleList: [], |
|
|
travleList: [], |
|
|
detailInfo: {}, |
|
|
detailInfo: {}, |
|
@ -262,7 +205,7 @@ export default { |
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
mounted() { |
|
|
mounted() { |
|
|
const {calcRate, windowDraw} = useIndex(this.$refs.appRef); |
|
|
const { calcRate, windowDraw } = useIndex(this.$refs.appRef); |
|
|
calcRate(); |
|
|
calcRate(); |
|
|
windowDraw(); |
|
|
windowDraw(); |
|
|
this.$nextTick(() => { |
|
|
this.$nextTick(() => { |
|
@ -277,7 +220,7 @@ export default { |
|
|
this.$http |
|
|
this.$http |
|
|
.post( |
|
|
.post( |
|
|
"/travel/selectTravelLineById", |
|
|
"/travel/selectTravelLineById", |
|
|
this.common.request({id}) |
|
|
this.common.request({ id }) |
|
|
) |
|
|
) |
|
|
.then((res) => { |
|
|
.then((res) => { |
|
|
if (res.data.code == 200 && res.data.data) { |
|
|
if (res.data.code == 200 && res.data.data) { |
|
@ -334,12 +277,12 @@ export default { |
|
|
this.driving.search( |
|
|
this.driving.search( |
|
|
lngList[0], |
|
|
lngList[0], |
|
|
lngList[lngLength - 1], |
|
|
lngList[lngLength - 1], |
|
|
{waypoints: this.trimmedLngList}, |
|
|
{ waypoints: this.trimmedLngList }, |
|
|
(status, result) => { |
|
|
(status, result) => { |
|
|
console.log(status, "status"); |
|
|
console.log(status, "status"); |
|
|
if (status === "complete") { |
|
|
if (status === "complete") { |
|
|
const {routes = []} = result; |
|
|
const { routes = [] } = result; |
|
|
const {steps = []} = routes[0]; |
|
|
const { steps = [] } = routes[0]; |
|
|
const pathArr = []; |
|
|
const pathArr = []; |
|
|
steps.map((i) => { |
|
|
steps.map((i) => { |
|
|
pathArr.push(i.path); |
|
|
pathArr.push(i.path); |
|
@ -445,7 +388,7 @@ export default { |
|
|
if (item.children && item.children.length > 0) { |
|
|
if (item.children && item.children.length > 0) { |
|
|
this.assembleData(item.children); |
|
|
this.assembleData(item.children); |
|
|
} else { |
|
|
} else { |
|
|
let dataItem = {...item}; |
|
|
let dataItem = { ...item }; |
|
|
dataItem.lnglat = [item.lng, item.lat]; |
|
|
dataItem.lnglat = [item.lng, item.lat]; |
|
|
try { |
|
|
try { |
|
|
dataItem.imageList = eval(dataItem.imageList); |
|
|
dataItem.imageList = eval(dataItem.imageList); |
|
@ -488,7 +431,7 @@ export default { |
|
|
this.$http |
|
|
this.$http |
|
|
.post( |
|
|
.post( |
|
|
"/travel/selectTravelInfoById", |
|
|
"/travel/selectTravelInfoById", |
|
|
this.common.request({id}) |
|
|
this.common.request({ id }) |
|
|
) |
|
|
) |
|
|
.then((res) => { |
|
|
.then((res) => { |
|
|
if (res.data.code == 200) { |
|
|
if (res.data.code == 200) { |
|
@ -619,10 +562,11 @@ export default { |
|
|
overflow: hidden; |
|
|
overflow: hidden; |
|
|
white-space: nowrap; |
|
|
white-space: nowrap; |
|
|
text-overflow: ellipsis; |
|
|
text-overflow: ellipsis; |
|
|
|
|
|
|
|
|
&:hover { |
|
|
&:hover { |
|
|
background-image: linear-gradient(90deg, |
|
|
background-image: linear-gradient(90deg, |
|
|
#12181f 0%, |
|
|
#12181f 0%, |
|
|
#293240 100%); |
|
|
#293240 100%); |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
@ -666,8 +610,8 @@ export default { |
|
|
height: 140px; |
|
|
height: 140px; |
|
|
border-radius: 8px; |
|
|
border-radius: 8px; |
|
|
background: linear-gradient(180deg, |
|
|
background: linear-gradient(180deg, |
|
|
rgba(0, 125, 165, 0.24) 0%, |
|
|
rgba(0, 125, 165, 0.24) 0%, |
|
|
rgba(1, 10, 43, 0) 100%); |
|
|
rgba(1, 10, 43, 0) 100%); |
|
|
display: flex; |
|
|
display: flex; |
|
|
flex-direction: column; |
|
|
flex-direction: column; |
|
|
justify-content: space-between; |
|
|
justify-content: space-between; |
|
@ -736,9 +680,12 @@ export default { |
|
|
width: 80px; |
|
|
width: 80px; |
|
|
font-size: 16px; |
|
|
font-size: 16px; |
|
|
display: inline-block; |
|
|
display: inline-block; |
|
|
overflow: hidden; /*超出部分隐藏*/ |
|
|
overflow: hidden; |
|
|
white-space: nowrap; /*禁止换行*/ |
|
|
/*超出部分隐藏*/ |
|
|
text-overflow: ellipsis; /*省略号*/ |
|
|
white-space: nowrap; |
|
|
|
|
|
/*禁止换行*/ |
|
|
|
|
|
text-overflow: ellipsis; |
|
|
|
|
|
/*省略号*/ |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
.text-type { |
|
|
.text-type { |
|
@ -794,8 +741,8 @@ export default { |
|
|
height: 140px; |
|
|
height: 140px; |
|
|
border-radius: 8px; |
|
|
border-radius: 8px; |
|
|
background: linear-gradient(180deg, |
|
|
background: linear-gradient(180deg, |
|
|
rgba(0, 125, 165, 0.24) 0%, |
|
|
rgba(0, 125, 165, 0.24) 0%, |
|
|
rgba(1, 10, 43, 0) 100%); |
|
|
rgba(1, 10, 43, 0) 100%); |
|
|
display: flex; |
|
|
display: flex; |
|
|
flex-direction: column; |
|
|
flex-direction: column; |
|
|
justify-content: space-between; |
|
|
justify-content: space-between; |
|
|