FIX точки маршрута в урле
This commit is contained in:
parent
498851352a
commit
12fe59d0fd
|
|
@ -30,6 +30,11 @@ function buildRoute(fit)
|
|||
wayPoints.push({latLng: points[$(el).attr('pointId')]._latlng});
|
||||
});
|
||||
|
||||
if (fit === true)
|
||||
{
|
||||
myMap.fitBounds(bounds).zoomOut();
|
||||
}
|
||||
|
||||
if (wayPoints.length > 1)
|
||||
{
|
||||
L.Routing.osrm().route(wayPoints, function(err, routes) {
|
||||
|
|
@ -50,15 +55,9 @@ function buildRoute(fit)
|
|||
route.addTo(myMap);
|
||||
}
|
||||
});
|
||||
|
||||
if (fit === true)
|
||||
{
|
||||
closeBox();
|
||||
myMap.fitBounds(bounds).zoomOut();
|
||||
}
|
||||
|
||||
routeToURL();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in New Issue