解决集结地点位经度越过180°时计算错误的问题
This commit is contained in:
@ -124,6 +124,9 @@ class DrawAssemble extends Draw {
|
||||
if (this.points_ids.length === 1) {
|
||||
let pnts = new Array();
|
||||
this.positions.forEach((item) => {
|
||||
if(item.lng<=0) {
|
||||
item.lng += 360
|
||||
}
|
||||
pnts.push([item.lng, item.lat]);
|
||||
});
|
||||
|
||||
|
@ -503,6 +503,9 @@ class Tools {
|
||||
let points = positions.length;
|
||||
let pnts = new Array();
|
||||
positions.forEach((item) => {
|
||||
if(item.lng<=0) {
|
||||
item.lng += 360
|
||||
}
|
||||
pnts.push([item.lng, item.lat]);
|
||||
});
|
||||
//console.log("pnts6666",pnts);
|
||||
|
Reference in New Issue
Block a user