diff options
Diffstat (limited to 'chimere/templates/search/search.html')
| -rw-r--r-- | chimere/templates/search/search.html | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/chimere/templates/search/search.html b/chimere/templates/search/search.html index 6539700..ff013fd 100644 --- a/chimere/templates/search/search.html +++ b/chimere/templates/search/search.html @@ -8,11 +8,25 @@ var end_do_you_mean = "{% trans '?' %}"; <div id='search-listing'> <ul> {% for result in results %} - <li> - <a href="#" onclick="$('#main-map').chimere('showPopup', '{{result.properties.key}}');return false;"> - <img src='{{MEDIA_URL}}{{result.properties.icon_path}}'/>{{ result.properties.name }} - </a> - </li> + {% ifchanged result.properties.category_name %} + {% if not forloop.first %} + </ul> + </li> + {% endif %} + <li> + <img src='{{MEDIA_URL}}{{result.properties.icon_path}}'/> + <span class="result-category-name">{{result.properties.category_name}}</span> + <ul> + {% endifchanged %} + <li> + <a href="#" onclick="$('#main-map').chimere('showPopup', '{{result.properties.key}}');return false;"> + {{ result.properties.name }} + </a> + </li> + {% if forloop.last %} + </ul> + </li> + {% endif %} {% empty %} <li>{% trans "No results found." %}</li> {% endfor %} |
