4d234fc3
liuqimichale
关闭esl
|
1
|
<template>
|
1e4db980
liuqimichale
轮廓
|
2
|
<div class="main-content">
|
1e4db980
liuqimichale
轮廓
|
3
4
|
<v-header></v-header>
<ul class="main-wrap">
|
86551874
liuqimichale
左右区域
|
5
|
<li class="main-left">
|
2caf9228
liuqimichale
公共卡片头部
|
6
|
<div class="frame-wrap">
|
633692cc
liuqimichale
axios
|
7
|
<v-parking :total="parkingTotal" :rodeside="rodeside" :rodeclose="rodeclose"></v-parking>
|
2caf9228
liuqimichale
公共卡片头部
|
8
|
</div>
|
d3312374
liuqimichale
收费员信息
|
9
|
<div class="frame-wrap frame-wrap-center">
|
633692cc
liuqimichale
axios
|
10
|
<v-toll :total="tollTotal" :tollsign="tollsign" :tollnosign="tollnosign"></v-toll>
|
d3312374
liuqimichale
收费员信息
|
11
|
</div>
|
dcff1e92
liuqimichale
进出场
|
12
|
<div class="frame-wrap">
|
633692cc
liuqimichale
axios
|
13
|
<v-inout :inoutmsg="inoutmsg" :inouttime="inouttime" :imgUrl="imgUrl"></v-inout>
|
dcff1e92
liuqimichale
进出场
|
14
|
</div>
|
86551874
liuqimichale
左右区域
|
15
|
</li>
|
1e4db980
liuqimichale
轮廓
|
16
|
<li class="main-center">
|
7d8d3bd4
liuqimichale
收入单位处理
|
17
|
<v-map :mapdata="ditudata" :lonId="lonId" :latId="latId"></v-map>
|
1e4db980
liuqimichale
轮廓
|
18
|
</li>
|
86551874
liuqimichale
左右区域
|
19
|
<li class="main-right">
|
6ee688df
liuqimichale
收入信息
|
20
|
<div class="frame-wrap">
|
633692cc
liuqimichale
axios
|
21
|
<v-income :total="incometotal" :barChartData="barChartData"></v-income>
|
6ee688df
liuqimichale
收入信息
|
22
|
</div>
|
ea141a52
liuqimichale
泊位
|
23
|
<div class="frame-wrap frame-wrap-center">
|
633692cc
liuqimichale
axios
|
24
|
<v-berth :total="bertotal" :pieChartData="pieChartData"></v-berth>
|
ea141a52
liuqimichale
泊位
|
25
|
</div>
|
93ff2951
liuqimichale
设备监控信息
|
26
|
<div class="frame-wrap">
|
633692cc
liuqimichale
axios
|
27
|
<v-equipment :equipment="equipment"></v-equipment>
|
93ff2951
liuqimichale
设备监控信息
|
28
|
</div>
|
86551874
liuqimichale
左右区域
|
29
|
</li>
|
1e4db980
liuqimichale
轮廓
|
30
31
|
</ul>
</div>
|
4d234fc3
liuqimichale
关闭esl
|
32
33
34
|
</template>
<script>
|
1e4db980
liuqimichale
轮廓
|
35
36
|
import VHeader from '../components/VHeader'
import VMap from '../components/VMap'
|
2caf9228
liuqimichale
公共卡片头部
|
37
|
import VParking from '../components/VParking'
|
d3312374
liuqimichale
收费员信息
|
38
|
import VToll from '../components/VToll'
|
dcff1e92
liuqimichale
进出场
|
39
|
import VInout from '../components/VInout'
|
6ee688df
liuqimichale
收入信息
|
40
|
import VIncome from '../components/VIncome'
|
ea141a52
liuqimichale
泊位
|
41
|
import VBerth from '../components/VBerth'
|
93ff2951
liuqimichale
设备监控信息
|
42
|
import VEquipment from '../components/VEquipment'
|
350097e4
liuqimichale
调取接口
|
43
|
|
04d7be6d
liuqimichale
进出场
|
44
|
import { parkAddress, tollAddress, incomeAddress, berthAddress, equipmentAddress, mapAddress, inoutAddress } from '../utils/api'
|
350097e4
liuqimichale
调取接口
|
45
|
|
4d234fc3
liuqimichale
关闭esl
|
46
|
export default {
|
1e4db980
liuqimichale
轮廓
|
47
48
49
|
name: 'VHome',
components: {
VHeader,
|
2caf9228
liuqimichale
公共卡片头部
|
50
|
VMap,
|
d3312374
liuqimichale
收费员信息
|
51
|
VParking,
|
dcff1e92
liuqimichale
进出场
|
52
|
VToll,
|
6ee688df
liuqimichale
收入信息
|
53
|
VInout,
|
ea141a52
liuqimichale
泊位
|
54
|
VIncome,
|
93ff2951
liuqimichale
设备监控信息
|
55
56
|
VBerth,
VEquipment
|
633692cc
liuqimichale
axios
|
57
58
59
|
},
data(){
return {
|
350097e4
liuqimichale
调取接口
|
60
61
62
63
64
65
|
parkingTotal: 0,
rodeside: 0,
rodeclose: 0,
tollTotal: 0,
tollsign: 0,
tollnosign: 0,
|
7d8d3bd4
liuqimichale
收入单位处理
|
66
67
|
inoutmsgstatus:'',
inoutmsg: '07:00',
|
ad451a08
liuqimichale
正式环境
|
68
|
inouttime: '',
|
efc9bf4b
liuqimichale
地图坐标
|
69
|
|
ad451a08
liuqimichale
正式环境
|
70
|
imgUrl: '',
|
350097e4
liuqimichale
调取接口
|
71
|
incometotal:0,
|
633692cc
liuqimichale
axios
|
72
|
barChartData:{
|
350097e4
liuqimichale
调取接口
|
73
74
|
seriesData:[0,0,0],
total:1
|
633692cc
liuqimichale
axios
|
75
|
},
|
350097e4
liuqimichale
调取接口
|
76
|
bertotal:0,
|
633692cc
liuqimichale
axios
|
77
|
pieChartData: {
|
350097e4
liuqimichale
调取接口
|
78
|
yData: [0,0],
|
633692cc
liuqimichale
axios
|
79
80
81
|
legendData: ['空余','占有']
},
equipment:{
|
ad451a08
liuqimichale
正式环境
|
82
83
84
85
86
87
88
89
90
91
92
93
|
PDA:0,
PDATotal:0,
pdaper:0,
berth:0,
berthTotal:0,
berthper:0,
daozha:0,
daozhaTotal:0,
daozhaper:0,
ydp:0,
ydpTotal:0,
ydpper:0
|
633692cc
liuqimichale
axios
|
94
|
},
|
efc9bf4b
liuqimichale
地图坐标
|
95
96
97
98
99
100
101
102
103
104
105
106
|
lonId:'',
latId:'',
ditudata:{
lonId:'',
latId:'',
data:[
{Name:'万达停车场1',lonId:'111.742579',latId:'40.818675',status:0,freeBrethNum:0,plBerthNum:1000,plName:'万达广场停车场1',plAddress:'北京万达广场1',income:123,arreageincome:100},
{Name:'万达停车场2',lonId:'111.622579',latId:'40.878675',status:1,freeBrethNum:100,plBerthNum:800,plName:'万达广场停车场2',plAddress:'北京万达广场2',income:123,arreageincome:100},
{Name:'万达停车场333333',lonId:'111.782579',latId:'40.778675',status:2,freeBrethNum:300,plBerthNum:500,plName:'万达广场停车场3',plAddress:'北京万达广场3',income:123,arreageincome:100}
],
}
|
633692cc
liuqimichale
axios
|
107
108
109
110
|
}
},
mounted(){
|
350097e4
liuqimichale
调取接口
|
111
112
|
//this.setmethod()
this.initView();
|
7d8d3bd4
liuqimichale
收入单位处理
|
113
|
this.initMAp();
|
04d7be6d
liuqimichale
进出场
|
114
|
this.setmethod()
|
350097e4
liuqimichale
调取接口
|
115
|
|
633692cc
liuqimichale
axios
|
116
117
118
|
},
methods:{
|
7d8d3bd4
liuqimichale
收入单位处理
|
119
120
121
122
123
124
125
126
127
|
initMAp(){
mapAddress({//地图
orgIds: this.GLOBAL.orignId
}).then((response)=>{
let data = response.data.data
console.log(data)
var tempData = [];
for(var index in data){
var item = data[index];
|
e30f1328
liuqimichale
地图坐标
|
128
|
//console.log(item.parkInfo.plName)
|
7d8d3bd4
liuqimichale
收入单位处理
|
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
|
if(item.parkInfo.lonId==null){
continue;
}
var tempItem =
{
Name: item.parkInfo.plName,
lonId: item.parkInfo.lonId,
latId:item.parkInfo.latId,
status: 0,
freeBrethNum: item.realTimeInfoDTO.berthFreeNum,
plBerthNum: item.realTimeInfoDTO.berthNum,
plName: item.parkInfo.plName,
plAddress: item.parkInfo.plAddress,
income:(item.realTimeInfoDTO.allIncome/100).toFixed(2),
arreageincome:(item.realTimeInfoDTO.escapeFee).toFixed(2)
}
tempData.push(tempItem);
}
|
efc9bf4b
liuqimichale
地图坐标
|
150
151
|
//this.ditudata.data = tempData;
this.$set(this.ditudata,'data',tempData)
|
7d8d3bd4
liuqimichale
收入单位处理
|
152
153
154
155
156
157
158
159
160
161
|
console.log(this.ditudata)
// ditudata:[
// {Name:'万达停车场1',lonId:'111.742579',latId:'40.818675',status:0,freeBrethNum:0,plBerthNum:1000,plName:'万达广场停车场1',plAddress:'北京万达广场1'},
// {Name:'万达停车场2',lonId:'111.622579',latId:'40.878675',status:1,freeBrethNum:100,plBerthNum:800,plName:'万达广场停车场2',plAddress:'北京万达广场2'},
// {Name:'万达停车场333333',lonId:'111.782579',latId:'40.778675',status:2,freeBrethNum:300,plBerthNum:500,plName:'万达广场停车场3',plAddress:'北京万达广场3'}
// ]
}).catch((response)=>{
console.log(response);
})
},
|
350097e4
liuqimichale
调取接口
|
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
|
initView(){
parkAddress({//停车场
orgIds: this.GLOBAL.orignId
}).then((response)=>{
let data = response.data.data
this.parkingTotal = data.allNum
this.rodeside = data.lcNum
this.rodeclose = data.fbNum
}).catch((response)=>{
console.log(response);
})
tollAddress({//收费员
orgIds: this.GLOBAL.orignId
}).then((response)=>{
let data = response.data.data
|
e30f1328
liuqimichale
地图坐标
|
177
178
179
180
181
182
183
|
// this.tollTotal = data.allTollCollector
// this.tollsign = data.signInTollCollector
// this.tollnosign = data.unSignInTollCollector
this.tollTotal = 36
this.tollsign = 28
this.tollnosign = 8
|
350097e4
liuqimichale
调取接口
|
184
185
186
187
|
}).catch((response)=>{
console.log(response);
})
|
04d7be6d
liuqimichale
进出场
|
188
|
inoutAddress({//进出场
|
ad451a08
liuqimichale
正式环境
|
189
|
orgIds: this.GLOBAL.orignId
|
04d7be6d
liuqimichale
进出场
|
190
191
|
}).then((response)=>{
let data = response.data.data
|
efc9bf4b
liuqimichale
地图坐标
|
192
|
//console.log(response)
|
04d7be6d
liuqimichale
进出场
|
193
|
let inoutdata = data[0]
|
e30f1328
liuqimichale
地图坐标
|
194
|
//console.log(inoutdata.parkState)
|
04d7be6d
liuqimichale
进出场
|
195
196
197
198
199
200
201
202
203
204
|
if(inoutdata.parkState == 10){
inoutdata.parkState = "进场"
this.inouttime = inoutdata.parkInTime
this.imgUrl = inoutdata.inCarUrl
}else{
inoutdata.parkState = "出场"
this.inouttime = inoutdata.parkOutTime
this.imgUrl = inoutdata.outCarUrl
}
this.inoutmsg = inoutdata.plName+' '+inoutdata.carNumber +' '+inoutdata.parkState
|
7d8d3bd4
liuqimichale
收入单位处理
|
205
|
if(this.inoutmsgstatus === this.inoutmsg){
|
7d8d3bd4
liuqimichale
收入单位处理
|
206
207
208
209
210
|
}else{
this.initMAp();
this.inoutmsgstatus = inoutdata.plName+' '+inoutdata.carNumber +' '+inoutdata.parkState
}
|
efc9bf4b
liuqimichale
地图坐标
|
211
212
|
// lonId:'',
// latId:'',
|
e30f1328
liuqimichale
地图坐标
|
213
|
//console.log(this.ditudata)
|
efc9bf4b
liuqimichale
地图坐标
|
214
215
|
this.$set(this.ditudata,'lonId',inoutdata.lonId)
this.$set(this.ditudata,'latId',inoutdata.latId)
|
04d7be6d
liuqimichale
进出场
|
216
217
218
219
|
}).catch((response)=>{
console.log(response);
})
|
350097e4
liuqimichale
调取接口
|
220
221
222
223
|
incomeAddress({//收入
orgIds: this.GLOBAL.orignId
}).then((response)=>{
let data = response.data.data
|
7376616d
liuqimichale
收入单位处理
|
224
|
this.incometotal = (data.totalPay/100).toFixed(0)
|
350097e4
liuqimichale
调取接口
|
225
|
this.barChartData = {
|
7376616d
liuqimichale
收入单位处理
|
226
227
|
seriesData:[(data.aliPay/100).toFixed(0),(data.wxPay/100).toFixed(0),(data.otherPay/100).toFixed(0)],
total:(data.totalPay/100).toFixed(0)
|
350097e4
liuqimichale
调取接口
|
228
|
}
|
350097e4
liuqimichale
调取接口
|
229
230
231
232
233
234
235
236
237
238
239
|
}).catch((response)=>{
console.log(response);
})
berthAddress({//泊位
orgIds: this.GLOBAL.orignId
}).then((response)=>{
let data = response.data.data
this.bertotal = data.allBerthNum
this.pieChartData = {
yData: [data.freeBerthNum,data.isOccupyBertnNum],
|
350097e4
liuqimichale
调取接口
|
240
241
242
243
244
245
|
}
}).catch((response)=>{
console.log(response);
})
|
ad451a08
liuqimichale
正式环境
|
246
247
|
|
84109d86
liuqimichale
地图 数据
|
248
249
|
|
350097e4
liuqimichale
调取接口
|
250
251
252
253
|
equipmentAddress({//设备
orgIds: this.GLOBAL.orignId
}).then((response)=>{
let data = response.data.data
|
e30f1328
liuqimichale
地图坐标
|
254
255
256
257
258
259
260
261
|
//
// if(data[0].onNum == 0){
// var PDAper = 0
// }else{
// var PDAper = ((data[0].onNum/data[0].num)*100).toFixed(2)
// }
|
e1915621
liuqimichale
调取接口
|
262
263
264
265
266
267
|
if(data[1].onNum == 0){
var berthper = 0
}else{
var berthper = ((data[1].onNum/data[1].num)*100).toFixed(2)
}
|
350097e4
liuqimichale
调取接口
|
268
|
|
e30f1328
liuqimichale
地图坐标
|
269
270
271
272
273
274
275
276
277
278
279
|
// if(data[2].onNum == 0){
// var daozhaper = 0
// }else{
// var daozhaper = ((data[2].onNum/data[2].num)*100).toFixed(2)
// }
//
// if(data[3].onNum == 0){
// var ydpper = 0
// }else{
// var ydpper = ((data[3].onNum/data[3].num)*100).toFixed(2)
// }
|
0ac0991c
liuqimichale
设备信息
|
280
281
|
|
e30f1328
liuqimichale
地图坐标
|
282
283
284
|
this.$set(this.equipment,'PDA',80)
this.$set(this.equipment,'PDATotal',90)
this.$set(this.equipment,'pdaper',((80/90)*100).toFixed(2))
|
350097e4
liuqimichale
调取接口
|
285
|
|
e1915621
liuqimichale
调取接口
|
286
287
288
|
this.$set(this.equipment,'berth',data[1].onNum)
this.$set(this.equipment,'berthTotal',data[1].num)
this.$set(this.equipment,'berthper',berthper)
|
0ac0991c
liuqimichale
设备信息
|
289
|
|
e30f1328
liuqimichale
地图坐标
|
290
291
292
293
294
295
296
297
298
299
|
// this.$set(this.equipment,'daozha',data[2].onNum)
// this.$set(this.equipment,'daozhaTotal',data[2].num)
// this.$set(this.equipment,'daozhaper',daozhaper)
this.$set(this.equipment,'daozha',2)
this.$set(this.equipment,'daozhaTotal',2)
this.$set(this.equipment,'daozhaper',((2/2)*100).toFixed(2))
//
// this.$set(this.equipment,'ydp',data[3].onNum)
// this.$set(this.equipment,'ydpTotal',data[3].num)
// this.$set(this.equipment,'ydpper',ydpper)
|
0ac0991c
liuqimichale
设备信息
|
300
|
|
e30f1328
liuqimichale
地图坐标
|
301
302
303
|
this.$set(this.equipment,'ydp',7)
this.$set(this.equipment,'ydpTotal',9)
this.$set(this.equipment,'ydpper',((7/9)*100).toFixed(2))
|
efc9bf4b
liuqimichale
地图坐标
|
304
|
|
350097e4
liuqimichale
调取接口
|
305
306
307
308
309
310
311
312
313
|
}).catch((response)=>{
console.log(response);
})
},
|
633692cc
liuqimichale
axios
|
314
|
setmethod(){
|
350097e4
liuqimichale
调取接口
|
315
|
|
633692cc
liuqimichale
axios
|
316
|
setInterval(()=>{
|
04d7be6d
liuqimichale
进出场
|
317
|
this.initView()
|
7d8d3bd4
liuqimichale
收入单位处理
|
318
319
320
321
|
},1000)
// setInterval(()=>{
// this.initMAp();
// },5000)
|
633692cc
liuqimichale
axios
|
322
|
}
|
04d7be6d
liuqimichale
进出场
|
323
324
|
},
|
4d234fc3
liuqimichale
关闭esl
|
325
326
327
|
}
</script>
|
1e4db980
liuqimichale
轮廓
|
328
329
330
331
332
333
334
335
336
337
338
339
340
341
|
<style scoped lang="scss">
.main-content{
width: 100%;
height: 100%;
}
.main-wrap{
height: calc(100% - 65px);
padding: 10px 10px;
li{
float: left;
height: 100%;
}
}
.main-left,.main-right{
|
1e4db980
liuqimichale
轮廓
|
342
343
344
345
346
347
348
|
width: 25%;
}
.main-center{
width: calc(50% - 20px);
margin: 0 10px;
border:1px solid #1679de;
}
|
86551874
liuqimichale
左右区域
|
349
350
351
352
353
|
.frame-wrap-center{
margin: 10px 0;
}
.frame-wrap{
height: calc((100% - 20px)/3);
|
f5d4b70c
liuqimichale
进出场信息
|
354
355
|
background: url("../images/content/frame-wrap.png");
background-size: 100% 100%;
|
6ee688df
liuqimichale
收入信息
|
356
|
overflow: hidden;
|
f5d4b70c
liuqimichale
进出场信息
|
357
358
359
360
361
|
/*border-image-source: url("../images/content/frame-wrap.png");*/
/*border-image-slice: 3 16 11 3 fill;*/
/*border-width: 3px 18px 11px 3px;*/
/*border-style: solid;*/
/*background-clip: border-box;*/
|
86551874
liuqimichale
左右区域
|
362
|
}
|
4d234fc3
liuqimichale
关闭esl
|
363
364
|
</style>
|