轨迹回放

This commit is contained in:
给我
2026-01-14 20:21:44 +08:00
parent 7e79ee273c
commit b13b7fed3e
2 changed files with 20 additions and 31 deletions

View File

@ -198,32 +198,23 @@ const saveUsers = (users) => {
listQuery.value.yjRyxm = users[0].yjRyxm; listQuery.value.yjRyxm = users[0].yjRyxm;
listQuery.value.yjRysfzh = users[0].yjRysfzh; listQuery.value.yjRysfzh = users[0].yjRysfzh;
qcckPost({ yjRysfzh: listQuery.value.yjRysfzh }, '/mosty-jcz/tbJczYjxx/getPageList').then((res) => { qcckPost({ yjRysfzh: listQuery.value.yjRysfzh }, '/mosty-jcz/tbJczYjxx/getPageList').then((res) => {
for (let i = 0; i < res.records.length; i++) { let list = res.records.map((item) => {
const item = res.records[i]; return [item.jd, item.wd]
emitter.emit("addPointArea", { })
coords: [{ jd: item.jd, wd: item.wd }], let obj = { coords: [list], text: '', id: '2222' }
icon: require("@/assets/point/zsdw.png"), console.log(obj, 'obj');
flag: "yjry_gj" emitter.emit("echoLine", {
flag: `yjry_gj`,
type: "solid",
coords: [obj], // 保持使用第一个数据点进行测试
isclear:true
});
emitter.emit("setMapCenter", { location: [res.records[0].jd, res.records[0].wd], zoomLevel: 10 });
emitter.emit("addPointArea", {
coords: [{ jd: res.records[0].jd, wd: res.records[0].wd }],
icon: require("@/assets/point/zsdw.png"),
flag: "jczMap_Gzy"
}); });
}
// let list = res.records.map((item) => {
// return [item.jd, item.wd]
// })
// let obj = { position: list, text: '', id: '2222' }
// console.log(obj, 'obj');
// emitter.emit("echoPlane", {
// flag: `yjry_gj`,
// type: "polygon",
// coords: [obj], // 保持使用第一个数据点进行测试
// fontSize: "20px",
// fontColor: '#000',
// });
// emitter.emit("setMapCenter", { location: [res.records[0].jd, res.records[0].wd], zoomLevel: 10 });
// emitter.emit("addPointArea", {
// coords: [{ jd: res.records[0].jd, wd: res.records[0].wd }],
// icon: require("@/assets/point/zsdw.png"),
// flag: "jczMap_Gzy"
// });
}); });
}; };

View File

@ -209,11 +209,11 @@ const getMapData = () => {
pyl: arrowhead[key].pyl, pyl: arrowhead[key].pyl,
}) })
} }
console.log(jtData,'jtData'); console.log(jtData, 'jtData');
// 修复后的多边形绘制代码 // 修复后的多边形绘制代码
for (let i = 0; i < jtData.length; i++) { for (let i = 0; i < jtData.length; i++) {
console.log(jtData[i],'jtData[i]'); console.log(jtData[i], 'jtData[i]');
console.log("正在绘制第", i, "个多边形"); console.log("正在绘制第", i, "个多边形");
emitter.emit("echoPlane", { emitter.emit("echoPlane", {
@ -315,6 +315,4 @@ const getMapData = () => {
box-sizing: border-box; box-sizing: border-box;
} }
} }
</style> </style>