diff --git a/mapobject/poi.go b/mapobject/poi.go index 0ec524d..711e3d5 100644 --- a/mapobject/poi.go +++ b/mapobject/poi.go @@ -17,6 +17,7 @@ func (this *PoiBlock) onMapObject(mbpos *types.MapBlockCoords, x, y, z int, bloc o := mapobjectdb.NewMapObject(mbpos, x, y, z, "poi") o.Attributes["name"] = md["name"] o.Attributes["category"] = md["category"] + o.Attributes["addr"] = md["addr"] o.Attributes["url"] = md["url"] o.Attributes["image"] = md["image"] o.Attributes["owner"] = md["owner"] diff --git a/public/js/map/overlays/PoiOverlay.js b/public/js/map/overlays/PoiOverlay.js index 89cbbe9..7f1cd76 100644 --- a/public/js/map/overlays/PoiOverlay.js +++ b/public/js/map/overlays/PoiOverlay.js @@ -35,7 +35,11 @@ export default AbstractIconOverlay.extend({ "\" crossorigin=\"anonymous\" referrerpolicy=\"origin-when-cross-origin\">"; } - innerHTML += "
Owner: " + HtmlSanitizer.SanitizeHtml(poi.attributes.owner) + "
"; + innerHTML += "
"; + if (poi.attributes.addr) { + innerHTML += "Address: " + HtmlSanitizer.SanitizeHtml(poi.attributes.addr) + "
"; + } + innerHTML += "Owner: " + HtmlSanitizer.SanitizeHtml(poi.attributes.owner) + "
"; return innerHTML; }