Commit 33daadfd authored by xxx's avatar xxx

1

parent 5e94f224
...@@ -2225,7 +2225,7 @@ var HttpReq = function(){ ...@@ -2225,7 +2225,7 @@ var HttpReq = function(){
params:param, params:param,
}) })
}, },
//获取地图车辆轨迹——获取轨迹列表 //获取地图车辆轨迹——获取停车时间以及地点轨迹列表
mineAlarmHistoryCountQuery: function(param){ mineAlarmHistoryCountQuery: function(param){
return request({ return request({
url: '/api/mineAlarmHistory/Count', url: '/api/mineAlarmHistory/Count',
...@@ -2233,6 +2233,14 @@ var HttpReq = function(){ ...@@ -2233,6 +2233,14 @@ var HttpReq = function(){
params:param, params:param,
}) })
}, },
//获取地图车辆轨迹——获取轨迹播放时间列表
apiMineAlarmHistoryTongJiQuery: function(param){
return request({
url: '/api/mineAlarmHistory/TongJi',
method: 'get',
params:param,
})
},
//获取地图车辆轨迹——获取所有实时坐标 //获取地图车辆轨迹——获取所有实时坐标
getAllNewTimeCarTrajectoryQuery: function(param){ getAllNewTimeCarTrajectoryQuery: function(param){
return request({ return request({
......
...@@ -94,6 +94,7 @@ export default { ...@@ -94,6 +94,7 @@ export default {
that.deviceId = equipmentName; that.deviceId = equipmentName;
that.carNumber = number; that.carNumber = number;
that.carPlaySpeed = speed; that.carPlaySpeed = speed;
console.log(that.carPlaySpeed);
that.stopPointData = stopPointData; that.stopPointData = stopPointData;
that.leadTime = leadTimeShow; that.leadTime = leadTimeShow;
//获取历史轨迹 //获取历史轨迹
......
...@@ -17,9 +17,7 @@ ...@@ -17,9 +17,7 @@
</el-form-item> </el-form-item>
<el-form-item label="*车牌号" style="display: inline-block;"> <el-form-item label="*车牌号" style="display: inline-block;">
<el-select v-model="query.number" placeholder="请选择车牌号"> <el-cascader v-model="carInforValue" :options="carInformationData" @change="handleChange"></el-cascader>
<el-option v-for="(obj,index) in carInformationData" :label="obj.number" :value="obj.number" :key="index"></el-option>
</el-select>
</el-form-item> </el-form-item>
<el-button type="success" icon="el-icon-search" @click="toSearch" style="display: inline-block;">搜索</el-button> <el-button type="success" icon="el-icon-search" @click="toSearch" style="display: inline-block;">搜索</el-button>
...@@ -58,8 +56,8 @@ ...@@ -58,8 +56,8 @@
<div class="trajectoryTableView"> <div class="trajectoryTableView">
<div style="font-size:20px;font-weight: 600;">播放时间列表</div> <div style="font-size:20px;font-weight: 600;">播放时间列表</div>
<el-table :data="playtimeTableData" border height="58.5vh"> <el-table :data="playtimeTableData" border height="58.5vh">
<el-table-column prop="date" label="启动时间" align="center"></el-table-column> <el-table-column prop="bTime" label="启动时间" align="center"></el-table-column>
<el-table-column prop="name" label="停车时间" align="center"></el-table-column> <el-table-column prop="eTime" label="停车时间" align="center"></el-table-column>
</el-table> </el-table>
</div> </div>
<div class="tishiTextStyle" v-if="tishiTextShow">请选择车辆查看轨迹</div> <div class="tishiTextStyle" v-if="tishiTextShow">请选择车辆查看轨迹</div>
...@@ -84,6 +82,7 @@ export default { ...@@ -84,6 +82,7 @@ export default {
return { return {
//地图图片 //地图图片
configUrl: basePathUrl + 'config/config.json', configUrl: basePathUrl + 'config/config.json',
carInforValue:[],
query:{ query:{
number:'', number:'',
bTime:'', bTime:'',
...@@ -91,7 +90,7 @@ export default { ...@@ -91,7 +90,7 @@ export default {
}, },
carInformationData:[], carInformationData:[],
shuaxinTimer:null, shuaxinTimer:null,
playSpeedNum:5, playSpeedNum:1,
tishiTextShow:true, tishiTextShow:true,
//停车时间以及地点数据 //停车时间以及地点数据
trajectoryTableData:[], trajectoryTableData:[],
...@@ -191,11 +190,11 @@ export default { ...@@ -191,11 +190,11 @@ export default {
} }
}) })
//获取右侧播放时间列表 //获取右侧播放时间列表
// HttpReq.truckDispatching.mineAlarmHistoryCountQuery({number:this.query.number,bTime:this.query.bTime,eTime:this.query.eTime}).then((res1) => { HttpReq.truckDispatching.apiMineAlarmHistoryTongJiQuery({number:this.query.number,bTime:this.query.bTime,eTime:this.query.eTime}).then((res1) => {
// if(res1.code == 200){ if(res1.code == 200){
this.playtimeTableData = res1.data;
// } }
// }) })
}else{ }else{
this.$notify({ this.$notify({
title: '暂无该车辆轨迹信息!', title: '暂无该车辆轨迹信息!',
...@@ -208,13 +207,12 @@ export default { ...@@ -208,13 +207,12 @@ export default {
}, },
// 重置搜索 // 重置搜索
clearLimit(){ clearLimit(){
this.query = { this.query = {number:'',bTime:'',eTime:''};
number:'', this.carInforValue = [];
bTime:'', this.playSpeedNum = 1;
eTime:'',
};
this.playSpeedNum = 5;
this.trajectoryTableData = []; this.trajectoryTableData = [];
this.playtimeTableData = [];
this.trajectoryTimePoint = '';
this.loadData(); this.loadData();
this.tishiTextShow = true; this.tishiTextShow = true;
this.shuaxinTimer = new Date().getTime(); this.shuaxinTimer = new Date().getTime();
...@@ -224,20 +222,42 @@ export default { ...@@ -224,20 +222,42 @@ export default {
//获取数据 //获取数据
loadData() { loadData() {
this.$nextTick(()=>{ this.$nextTick(()=>{
//获取车辆信息 //获取车队
HttpReq.truckDispatching.carInformationQuery({size:9999}).then((res) => { let arr1 = [];
if(res.code == 200){; HttpReq.truckDispatching.carFleetQuery({size:9999}).then((res1) => {
this.carInformationData = res.data.content; if(res1.code == 200){
//获取车辆信息
HttpReq.truckDispatching.carInformationQuery({size:9999}).then((res2) => {
if(res2.code == 200){
res1.data.content.forEach((item1,index1)=>{
let obj1 = {};
obj1.value = item1.name;
obj1.label = item1.name;
obj1.children = [];
res2.data.content.forEach((item2,index2)=>{
if(item1.name == item2.road){
let obj2 = {};
obj2.value = item2.number;
obj2.label = item2.number;
obj1.children.push(obj2);
}
})
arr1.push(obj1);
})
this.carInformationData = arr1;
}
})
} }
}) })
}) })
}, },
//改变倍速 //改变倍速
changeSpeed(num){ changeSpeed(num){
let that = this; let that = this;
let numSpeed1 = 5 / parseFloat(num); let numSpeed1 = parseFloat(num);
this.playSpeedNum = parseFloat(numSpeed1); this.playSpeedNum = parseFloat(num);
if(this.query.number == '' || this.query.bTime == '' || this.query.eTime == ''){ if(this.query.number == '' || this.query.bTime == '' || this.query.eTime == ''){
return; return;
}else{ }else{
...@@ -274,6 +294,14 @@ export default { ...@@ -274,6 +294,14 @@ export default {
}) })
} }
}, },
//选择车辆级联器
handleChange(){
if(this.carInforValue.length == 2){
this.query.number = this.carInforValue[1];
}else{
this.query.number = '';
}
},
// 地图构造完成回调 // 地图构造完成回调
onMapload(map) { onMapload(map) {
// 以下为演示代码 // 以下为演示代码
......
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