Skip to content

Commit

Permalink
Print debug times and succeed index, query in answer.html.
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinMikita committed Jul 21, 2016
1 parent 314b657 commit dd81f11
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
4 changes: 4 additions & 0 deletions web/templates/answer.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
<hr>
{% if rc %}
<p>Found <b>{{ result['totalResults'] }}</b> results for <i>{{query}}</i> in <i>{{index}}</i>:</p>
<p>Used index {{result['index_succeed']}} for query <i>{{result['query_succeed']}}</i> with modify {{result['modify']}}</p>
{% if 'times' in result %}
<p>Times: prepare {{result['times']['prepare']}}, total {{result['times']['process']}}</p>
{% endif %}
<p>Showing <b>{{ result['results'] | length }}</b> results</p>
<table class="entries" width="100%" border="1" style="border-collapse: collapse;">
<tr>
Expand Down
3 changes: 3 additions & 0 deletions web/templates/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ <h1>OSM Names full text search</h1>
<form name="display_name" action="{{ route }}" method="get">
Search: <input autocomplete="off" id="autocomplete" type="text" name="q" value="{{query}}" class="autocomplete-nominatim" autofocus="autofocus" /><br/>
<input type="hidden" name="format" value="html" />
{% if result and 'times' in result %}
<input type="hidden" name="debug" value="1" />
{% endif %}
<input class="btn" type="submit" value="Search" />
</form>
{% endblock %}
Expand Down

0 comments on commit dd81f11

Please sign in to comment.