岗亭车点位上图

lukeyan
lukeyan 12 months ago
parent 4cc4727458
commit b65c5b4b67

@ -54,4 +54,12 @@ export function camera_point(params) {
method:'get', method:'get',
params params
}) })
}
// 岗亭车
export function patrol_point(params) {
return request({
url:'/ThreeProoFingsData/SentryBoxList',
method:'get',
params
})
} }

@ -29,6 +29,11 @@ export default {
type: Array, type: Array,
default: () => [], default: () => [],
}, },
//
patrol_list: {
type: Array,
default: () => [],
},
// //
new_line: { new_line: {
type: Array, type: Array,
@ -124,7 +129,9 @@ export default {
imageOffset: new BMap.Size(0, 0, 5), // imageOffset: new BMap.Size(0, 0, 5), //
} }
); );
var camera_marker = new BMap.Marker(camera_point, { icon: camera_icon }); // var camera_marker = new BMap.Marker(camera_point, {
icon: camera_icon,
}); //
map.addOverlay(camera_marker); map.addOverlay(camera_marker);
// camera_marker.addEventListener("click", function () { // camera_marker.addEventListener("click", function () {
// // // //
@ -132,6 +139,23 @@ export default {
// that.$emit("get_car_text", item); // that.$emit("get_car_text", item);
// }); // });
}); });
//
that.patrol_list.forEach((item) => {
var patrol_point = new BMap.Point(item.longitude, item.latitude);
// ;
var patrol_icon = {};
patrol_icon = new BMap.Icon(
require("@/assets/factor/factor03.png"),
new BMap.Size(20, 40),
{
imageOffset: new BMap.Size(0, 0, 5), //
}
);
var patrol_marker = new BMap.Marker(patrol_point, {
icon: patrol_icon,
}); //
map.addOverlay(patrol_marker);
});
}, 500); }, 500);
map.centerAndZoom( map.centerAndZoom(
new BMap.Point(this.center_point[0], this.center_point[1]), new BMap.Point(this.center_point[0], this.center_point[1]),

@ -11,6 +11,7 @@
:video_list="video_list" :video_list="video_list"
:car_list="car_list" :car_list="car_list"
:camera_list="camera_list" :camera_list="camera_list"
:patrol_list="patrol_list"
@get_company_text="get_company_text" @get_company_text="get_company_text"
@get_video_text="get_video_text" @get_video_text="get_video_text"
@get_car_text="get_car_text" @get_car_text="get_car_text"
@ -62,6 +63,9 @@
<el-button size="small" @click="get_camera()">{{ <el-button size="small" @click="get_camera()">{{
this.btn_camera this.btn_camera
}}</el-button> }}</el-button>
<el-button size="small" @click="get_patrol()">{{
this.btn_patrol
}}</el-button>
</div> </div>
</div> </div>
<!-- 公司信息文本展示 --> <!-- 公司信息文本展示 -->
@ -164,6 +168,7 @@ import {
car_point, car_point,
car_line, car_line,
camera_point, camera_point,
patrol_point
} from "@/api/factorResources"; } from "@/api/factorResources";
export default { export default {
name: "factor", name: "factor",
@ -176,6 +181,7 @@ export default {
video_list: [], // video_list: [], //
car_list: [], // car_list: [], //
camera_list: [], // camera_list: [], //
patrol_list:[], //
search: { search: {
word: "", word: "",
select: "企业", select: "企业",
@ -188,6 +194,7 @@ export default {
btn_item: "", // btn_item: "", //
btn_car: "", // btn_car: "", //
btn_camera: "", // btn_camera: "", //
btn_patrol:'', //
company_flag: "0", // company_flag: "0", //
/////////// ///////////
text_company: "", text_company: "",
@ -213,10 +220,10 @@ export default {
}, },
created() { created() {
this.get_list(); this.get_list();
// this.get_video(); //
this.get_video();
this.get_car_point(); this.get_car_point();
this.get_camera_point(); this.get_camera_point();
this.get_patrol_point()
}, },
methods: { methods: {
// //
@ -229,14 +236,14 @@ export default {
}); });
}, },
// //
get_all() { // get_all() {
statistic().then((res) => { // statistic().then((res) => {
this.company_list = res.data.companyInfoList; // this.company_list = res.data.companyInfoList;
this.video_list = res.data.deviceVideoInfoList; // this.video_list = res.data.deviceVideoInfoList;
// // //
this.$refs.factorMap.init_map(); // this.$refs.factorMap.init_map();
}); // });
}, // },
// //
get_item() { get_item() {
this.company_flag = "0"; this.company_flag = "0";
@ -247,6 +254,8 @@ export default {
this.company_list = res.data; this.company_list = res.data;
this.video_list = []; this.video_list = [];
this.car_list = []; this.car_list = [];
this.patrol_list= [];
this.camera_list = [];
// //
this.$refs.factorMap.init_map(); this.$refs.factorMap.init_map();
}); });
@ -259,6 +268,7 @@ export default {
}; };
queryVideo(param).then((res) => { queryVideo(param).then((res) => {
this.video_list = res.data; this.video_list = res.data;
this.patrol_list= [];
this.camera_list = []; this.camera_list = [];
this.company_list = []; this.company_list = [];
this.car_list = []; this.car_list = [];
@ -273,6 +283,7 @@ export default {
console.log("resss", res); console.log("resss", res);
if (res.code == 200) { if (res.code == 200) {
this.car_list = res.data; this.car_list = res.data;
this.patrol_list= [];
this.camera_list = []; this.camera_list = [];
this.company_list = []; this.company_list = [];
this.video_list = []; this.video_list = [];
@ -289,6 +300,23 @@ export default {
let res = await camera_point(); let res = await camera_point();
if (res.code == 200) { if (res.code == 200) {
this.camera_list = res.data; this.camera_list = res.data;
this.patrol_list= [];
this.car_list = [];
this.company_list = [];
this.video_list = [];
//
this.$refs.factorMap.init_map();
} else if (res.code == 500) {
this.$message.warning(res.msg);
}
},
//
async get_patrol() {
this.company_flag = "0";
let res = await patrol_point()
if (res.code == 200) {
this.patrol_list = res.data;
this.camera_list = []
this.car_list = []; this.car_list = [];
this.company_list = []; this.company_list = [];
this.video_list = []; this.video_list = [];
@ -394,6 +422,15 @@ export default {
this.$message.warning(res.msg); this.$message.warning(res.msg);
} }
}, },
async get_patrol_point() {
let res = await patrol_point()
if (res.code == 200) {
// this.car_list = res.data
this.btn_patrol = `岗亭车辆(${res.data.length})`;
} else if (res.code == 500) {
this.$message.warning(res.msg);
}
},
// //
turn() { turn() {
sessionStorage.setItem("companyID", this.id); sessionStorage.setItem("companyID", this.id);
@ -527,7 +564,7 @@ export default {
} }
.left_check { .left_check {
width: 13vw; width: 13vw;
height: 23vh; height: 27vh;
border: 0.1px solid #28847e; border: 0.1px solid #28847e;
background: #212f30; background: #212f30;
border-radius: 4px; border-radius: 4px;
@ -546,7 +583,7 @@ export default {
margin-top: 1vh; margin-top: 1vh;
margin-left: 1vw; margin-left: 1vw;
width: 11vw; width: 11vw;
height: 18vh; height: 22vh;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
.el-button { .el-button {

Loading…
Cancel
Save