1
0
forked from MTSR/mapserver

wip support for colored pois with icons in search result

This commit is contained in:
NatureFreshMilk 2019-05-03 08:20:03 +02:00
parent b7749327fd
commit af95772045

View File

@ -40,7 +40,13 @@ var SearchResult = {
if (obj.type == "poi"){
description = m("span", obj.attributes.name);
type = m("img", { src: "css/images/marker-icon.png" });
var color = obj.attributes.color || "blue";
var icon = obj.attributes.icon || "home";
type = m("div", { class: "awesome-marker awesome-marker-icon-" + color }, [
m("i", { class: "fa fa-" + icon })
]);
}
if (obj.type == "shop") {