label search

This commit is contained in:
NatureFreshMilk 2019-06-11 13:49:23 +02:00
parent 043a857cee
commit 3adcec1df4
3 changed files with 8 additions and 1 deletions

View File

@ -46,6 +46,12 @@ var SearchResult = {
type = m("img", { src: "pics/bones_top.png" });
}
// label
if (obj.type == "label"){
description = m("span", obj.attributes.text);
type = m("img", { src: "pics/mapserver_label.png" });
}
// locator
if (obj.type == "locator"){
description = m("span", obj.attributes.name);

View File

@ -35,7 +35,8 @@ var SearchService = {
searchFor("train", "station", SearchStore.query),
searchFor("travelnet", "station_name", SearchStore.query),
searchFor("bones", "owner", SearchStore.query),
searchFor("locator", "name", SearchStore.query)
searchFor("locator", "name", SearchStore.query),
searchFor("label", "text", SearchStore.query)
];
Promise.all(prom_list)

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB