Commit b42f6530 authored by Administrator's avatar Administrator

设备地图定位

parent 59c6d81a
...@@ -277,6 +277,13 @@ export default { ...@@ -277,6 +277,13 @@ export default {
watch: { watch: {
}, },
mounted() { mounted() {
console.log(this.$route.query);
if (this.$route.query.device_id > 0) {
this.markersDeviceVisible = true;
this.zoom = 15;
console.log(this.$route.query.device_id);
this.markerClickEvent({ id: this.$route.query.device_id });
}
}, },
created() { created() {
this.$store.dispatch('app/toggleSideBar'); this.$store.dispatch('app/toggleSideBar');
......
...@@ -72,12 +72,12 @@ ...@@ -72,12 +72,12 @@
<span>{{ scope.row.tname }}</span> <span>{{ scope.row.tname }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="检测介质" width="170"> <el-table-column align="center" label="检测介质" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.row.gas }}</span> <span>{{ scope.row.gas }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="切断装置" width="170"> <el-table-column align="center" label="切断装置" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ shutoffDevice(scope.row.shutoff_type) }}</span> <span>{{ shutoffDevice(scope.row.shutoff_type) }}</span>
</template> </template>
...@@ -92,7 +92,7 @@ ...@@ -92,7 +92,7 @@
<span>{{ scope.row.danwei }}</span> <span>{{ scope.row.danwei }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="切断装置状态" width="120"> <el-table-column align="center" label="切断装置状态" width="80">
<template slot-scope="scope"> <template slot-scope="scope">
<span> <span>
<el-popconfirm <el-popconfirm
...@@ -131,6 +131,13 @@ ...@@ -131,6 +131,13 @@
<span v-if="scope.row.update_time > 0">{{ scope.row.update_time | parseTime('{y}-{m}-{d} {h}:{i}:{s}') }}</span> <span v-if="scope.row.update_time > 0">{{ scope.row.update_time | parseTime('{y}-{m}-{d} {h}:{i}:{s}') }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column align="center" label="--" width="120">
<template slot-scope="scope">
<router-link :to="{ path: '/map/map', query: { device_id: scope.row.id } }">
<el-button class="button">查看地图</el-button>
</router-link>
</template>
</el-table-column>
</el-table> </el-table>
<pagination <pagination
v-show="total>0" v-show="total>0"
......
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