|
@ -1,6 +1,19 @@ |
|
|
<template> |
|
|
<template> |
|
|
<div class="brand-container"> |
|
|
<div class="brand-container"> |
|
|
<div class="wrap"> |
|
|
<div class="dialog" v-if="!showFlag"> |
|
|
|
|
|
<div class="dialog-header"> |
|
|
|
|
|
<div class="text">选择显示车场</div> |
|
|
|
|
|
<div class="allBtn" @mouseenter="parkingInfoId = null" @mouseleave="parkingInfoId = ''" |
|
|
|
|
|
@click="parkingInfoId = ''; showBi()">查看全部</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="dialog-body"> |
|
|
|
|
|
<div class="dialog-item" :class="parkingInfoId === null ? 'select' : ''" v-for="(item, index) in PkParkingInfo" |
|
|
|
|
|
:key="index" @click="parkingInfoId = item.value; showBi()"> |
|
|
|
|
|
<span>{{ item.label }}</span> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="wrap" v-else> |
|
|
<header> |
|
|
<header> |
|
|
<div class="showTime"> |
|
|
<div class="showTime"> |
|
|
<span class="time">{{ nowTime }}</span> |
|
|
<span class="time">{{ nowTime }}</span> |
|
@ -10,6 +23,9 @@ |
|
|
</span> |
|
|
</span> |
|
|
</div> |
|
|
</div> |
|
|
<h2>智慧云停车大数据平台</h2> |
|
|
<h2>智慧云停车大数据平台</h2> |
|
|
|
|
|
<div class="screenFull"> |
|
|
|
|
|
<screenfull /> |
|
|
|
|
|
</div> |
|
|
<div class="welcome">欢迎使用本系统</div> |
|
|
<div class="welcome">欢迎使用本系统</div> |
|
|
</header> |
|
|
</header> |
|
|
|
|
|
|
|
@ -104,8 +120,10 @@ |
|
|
</div> |
|
|
</div> |
|
|
<div class="item"> |
|
|
<div class="item"> |
|
|
<p class="p1">周转率</p> |
|
|
<p class="p1">周转率</p> |
|
|
<p class="p2"> <span v-if="useCarCon.parkingPlaceTurnover">{{ parseInt(useCarCon.parkingPlaceTurnover * 100)}}%</span> |
|
|
<p class="p2"> <span v-if="useCarCon.parkingPlaceTurnover">{{ parseInt(useCarCon.parkingPlaceTurnover |
|
|
<span v-else>0%</span> |
|
|
* 100) |
|
|
|
|
|
}}%</span> |
|
|
|
|
|
<span v-else>0%</span> |
|
|
</p> |
|
|
</p> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
@ -157,6 +175,12 @@ export default { |
|
|
}, |
|
|
}, |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
|
|
|
// 是否显示大数据页面 |
|
|
|
|
|
showFlag: false, |
|
|
|
|
|
// 所有车场列表 |
|
|
|
|
|
PkParkingInfo: [], |
|
|
|
|
|
// 选中车场id |
|
|
|
|
|
parkingInfoId: '', |
|
|
// 车场排行数据 |
|
|
// 车场排行数据 |
|
|
rankData: [], |
|
|
rankData: [], |
|
|
// 支付统计数据 |
|
|
// 支付统计数据 |
|
@ -204,15 +228,15 @@ export default { |
|
|
}, |
|
|
}, |
|
|
mounted() { |
|
|
mounted() { |
|
|
if (authCode && typeof +authCode === 'number') { |
|
|
if (authCode && typeof +authCode === 'number') { |
|
|
// this.$showLoading(); |
|
|
BiApi.getPkParkingInfo({ authCode }).then((res) => { |
|
|
this.heart(); |
|
|
if (res.length > 0) { |
|
|
setTimeout(() => { |
|
|
this.PkParkingInfo = res |
|
|
this.getEchart(); |
|
|
} else { |
|
|
}, 800); |
|
|
this.showFlag = true |
|
|
// loading |
|
|
this.showBi(); |
|
|
// setTimeout(() => { |
|
|
} |
|
|
// this.$hideLoading(); |
|
|
}) |
|
|
// }, 900); |
|
|
|
|
|
} else { |
|
|
} else { |
|
|
// console.log('授权码为空', authCode); |
|
|
// console.log('授权码为空', authCode); |
|
|
alert('授权码为空,请从系统调用页面!') |
|
|
alert('授权码为空,请从系统调用页面!') |
|
@ -223,6 +247,21 @@ export default { |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
/** |
|
|
|
|
|
* 显示大数据画面 |
|
|
|
|
|
*/ |
|
|
|
|
|
showBi() { |
|
|
|
|
|
// this.$showLoading(); |
|
|
|
|
|
this.showFlag = true; |
|
|
|
|
|
this.heart(); |
|
|
|
|
|
setTimeout(() => { |
|
|
|
|
|
this.getEchart(); |
|
|
|
|
|
}, 800); |
|
|
|
|
|
// loading |
|
|
|
|
|
// setTimeout(() => { |
|
|
|
|
|
// this.$hideLoading(); |
|
|
|
|
|
// }, 900); |
|
|
|
|
|
}, |
|
|
/** |
|
|
/** |
|
|
* 格式化时钟函数 |
|
|
* 格式化时钟函数 |
|
|
*/ |
|
|
*/ |
|
@ -243,10 +282,25 @@ export default { |
|
|
this.getData(); |
|
|
this.getData(); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
/** |
|
|
|
|
|
* 心跳函数,每秒执行一次 |
|
|
|
|
|
*/ |
|
|
|
|
|
heart() { |
|
|
|
|
|
this.clear(); |
|
|
|
|
|
this.heartCallBack() // 首次加载 |
|
|
|
|
|
this.timer = setInterval(this.heartCallBack, 1000); |
|
|
|
|
|
}, |
|
|
|
|
|
clear() { |
|
|
|
|
|
clearInterval(this.timer); |
|
|
|
|
|
this.timer = null; |
|
|
|
|
|
this.heartTimes = 0; |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
getData() { |
|
|
getData() { |
|
|
|
|
|
//公共请求参数 |
|
|
|
|
|
const publicObj = this.parkingInfoId ? { authCode, parkingInfoId: this.parkingInfoId } : { authCode }; |
|
|
// 今日交易金额-笔数数据 |
|
|
// 今日交易金额-笔数数据 |
|
|
BiApi.getTodayTrade({ authCode }).then((res) => { |
|
|
BiApi.getTodayTrade(publicObj).then((res) => { |
|
|
// console.log(res); |
|
|
// console.log(res); |
|
|
if (res && res.code === 200) { |
|
|
if (res && res.code === 200) { |
|
|
const { totalAmount, totalNum } = res.data |
|
|
const { totalAmount, totalNum } = res.data |
|
@ -259,35 +313,35 @@ export default { |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
// 实时进出信息 |
|
|
// 实时进出信息 |
|
|
BiApi.getRealTimeInOutRecord({ authCode, pageNum: 1, pageSize: 10 }).then((res) => { |
|
|
BiApi.getRealTimeInOutRecord({ authCode, pageNum: 1, pageSize: 10, parkingInfoId: this.parkingInfoId }).then((res) => { |
|
|
if (res && res.code === 200) { |
|
|
if (res && res.code === 200) { |
|
|
this.realTimeInOutRecord = res.rows |
|
|
this.realTimeInOutRecord = res.rows |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
// 开放统计-车场排行 |
|
|
// 开放统计-车场排行 |
|
|
BiApi.getParkingRanking({ authCode }).then((res) => { |
|
|
BiApi.getParkingRanking(publicObj).then((res) => { |
|
|
if (res && res.code === 200) this.rankData = res.data |
|
|
if (res && res.code === 200) this.rankData = res.data |
|
|
}) |
|
|
}) |
|
|
// 开放统计-支付统计 |
|
|
// 开放统计-支付统计 |
|
|
BiApi.paymentStatistics({ authCode }).then((res) => { |
|
|
BiApi.paymentStatistics(publicObj).then((res) => { |
|
|
if (res && res.code === 200) this.payData = res.data |
|
|
if (res && res.code === 200) this.payData = res.data |
|
|
}) |
|
|
}) |
|
|
// 开放统计-收费车辆统计 |
|
|
// 开放统计-收费车辆统计 |
|
|
BiApi.amountCartStatistics({ authCode }).then((res) => { |
|
|
BiApi.amountCartStatistics(publicObj).then((res) => { |
|
|
if (res && res.code === 200) this.payDataCar = res.data |
|
|
if (res && res.code === 200) this.payDataCar = res.data |
|
|
}) |
|
|
}) |
|
|
// 开放统计-24小时车流统计 |
|
|
// 开放统计-24小时车流统计 |
|
|
BiApi.todayTrafficStatistics({ authCode }).then((res) => { |
|
|
BiApi.todayTrafficStatistics(publicObj).then((res) => { |
|
|
if (res && res.code === 200) this.todayTraffic = res.data |
|
|
if (res && res.code === 200) this.todayTraffic = res.data |
|
|
}) |
|
|
}) |
|
|
// 开放统计-24小时车辆使用统计 |
|
|
// 开放统计-24小时车辆使用统计 |
|
|
BiApi.todayCarUseStatistics({ authCode }).then((res) => { |
|
|
BiApi.todayCarUseStatistics(publicObj).then((res) => { |
|
|
if (res && res.code === 200) this.todayCarUse = res.data |
|
|
if (res && res.code === 200) this.todayCarUse = res.data |
|
|
}) |
|
|
}) |
|
|
BiApi.useCarStatistics({ authCode }).then((res) => { |
|
|
BiApi.useCarStatistics(publicObj).then((res) => { |
|
|
if (res && res.code === 200) this.useCarCon = res.data |
|
|
if (res && res.code === 200) this.useCarCon = res.data |
|
|
}) |
|
|
}) |
|
|
BiApi.parkingCarNum({ authCode }).then((res) => { |
|
|
BiApi.parkingCarNum(publicObj).then((res) => { |
|
|
this.geoCoordMap = { |
|
|
this.geoCoordMap = { |
|
|
上海: [121.4648, 31.2891], |
|
|
上海: [121.4648, 31.2891], |
|
|
东莞: [113.8953, 22.901], |
|
|
东莞: [113.8953, 22.901], |
|
@ -417,19 +471,7 @@ export default { |
|
|
}) |
|
|
}) |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
/** |
|
|
|
|
|
* 心跳函数,每秒执行一次 |
|
|
|
|
|
*/ |
|
|
|
|
|
heart() { |
|
|
|
|
|
this.clear(); |
|
|
|
|
|
this.heartCallBack() // 首次加载 |
|
|
|
|
|
this.timer = setInterval(this.heartCallBack, 1000); |
|
|
|
|
|
}, |
|
|
|
|
|
clear() { |
|
|
|
|
|
clearInterval(this.timer); |
|
|
|
|
|
this.timer = null; |
|
|
|
|
|
this.heartTimes = 0; |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
convertData(data) { |
|
|
convertData(data) { |
|
|
// 地图数据转换 |
|
|
// 地图数据转换 |
|
@ -734,6 +776,85 @@ export default { |
|
|
height: 100%; |
|
|
height: 100%; |
|
|
background: #000; |
|
|
background: #000; |
|
|
|
|
|
|
|
|
|
|
|
.dialog { |
|
|
|
|
|
width: 100%; |
|
|
|
|
|
height: 100%; |
|
|
|
|
|
background: #fff; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.dialog-header { |
|
|
|
|
|
position: relative; |
|
|
|
|
|
width: 15rem; |
|
|
|
|
|
color: #0d1c28; |
|
|
|
|
|
line-height: 1; |
|
|
|
|
|
margin: 0 auto; |
|
|
|
|
|
padding: 0.6rem 0 0.2rem; |
|
|
|
|
|
border-bottom: 0.06rem solid #0d1c28; |
|
|
|
|
|
font-size: 0.3rem; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.allBtn { |
|
|
|
|
|
position: absolute; |
|
|
|
|
|
top: 0.6rem; |
|
|
|
|
|
right: 0.34rem; |
|
|
|
|
|
width: 1.4rem; |
|
|
|
|
|
height: 0.45rem; |
|
|
|
|
|
line-height: 0.45rem; |
|
|
|
|
|
border-radius: 0.04rem; |
|
|
|
|
|
font-size: 0.24rem; |
|
|
|
|
|
text-align: center; |
|
|
|
|
|
font-weight: 600; |
|
|
|
|
|
background: #f1f2f3; |
|
|
|
|
|
|
|
|
|
|
|
&:hover { |
|
|
|
|
|
background: #409eff; |
|
|
|
|
|
color: #f1f2f3; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
&.select { |
|
|
|
|
|
background: #409eff; |
|
|
|
|
|
color: #f1f2f3; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.dialog-body { |
|
|
|
|
|
position: relative; |
|
|
|
|
|
width: 15rem; |
|
|
|
|
|
margin: 0 auto; |
|
|
|
|
|
display: flex; |
|
|
|
|
|
flex-wrap: wrap; |
|
|
|
|
|
|
|
|
|
|
|
.dialog-item { |
|
|
|
|
|
display: block; |
|
|
|
|
|
width: 4.75rem; |
|
|
|
|
|
height: 1rem; |
|
|
|
|
|
line-height: 1rem; |
|
|
|
|
|
box-sizing: border-box; |
|
|
|
|
|
margin: 0.2rem 0.2rem 0.2rem 0; |
|
|
|
|
|
padding: 0 0.2rem; |
|
|
|
|
|
font-size: 0.225rem; |
|
|
|
|
|
background: #f1f2f3; |
|
|
|
|
|
font-weight: 600; |
|
|
|
|
|
border-radius: 0.08rem; |
|
|
|
|
|
|
|
|
|
|
|
&:hover { |
|
|
|
|
|
background: #409eff; |
|
|
|
|
|
color: #f1f2f3; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
&.select { |
|
|
|
|
|
background: #409eff; |
|
|
|
|
|
color: #f1f2f3; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
.wrap { |
|
|
.wrap { |
|
|
background: url(../assets/img/brand/bg.png) no-repeat #000; |
|
|
background: url(../assets/img/brand/bg.png) no-repeat #000; |
|
|
background-size: cover; |
|
|
background-size: cover; |
|
@ -779,6 +900,15 @@ export default { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.screenFull { |
|
|
|
|
|
position: absolute; |
|
|
|
|
|
right: 2.6rem; |
|
|
|
|
|
top: 0.5rem; |
|
|
|
|
|
width: 0.25rem; |
|
|
|
|
|
height: 0.25rem; |
|
|
|
|
|
cursor: pointer; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
.welcome { |
|
|
.welcome { |
|
|
position: absolute; |
|
|
position: absolute; |
|
|
right: 0.625rem; |
|
|
right: 0.625rem; |
|
|