[search] show outline and icon from nominatim

This commit is contained in:
fkloft
2015-02-12 19:29:19 +01:00
parent 455e2c0535
commit 6533dd5d0d
3 changed files with 13 additions and 1 deletions

View File

@ -274,8 +274,19 @@ addHook('search', function(query) {
title: item.display_name,
description: 'Type: ' + item.type,
position: L.latLng(parseFloat(item.lat), parseFloat(item.lon)),
icon: item.icon,
};
if(item.geojson) {
result.layer = L.geoJson(item.geojson, {
clickable: false,
color: 'red',
opacity: 0.7,
weight: 2,
fill: false,
});
}
var b = item.boundingbox;
if(b) {
var southWest = new L.LatLng(b[0], b[2]),