forked from Ponysearch/Ponysearch
[mod] UI: engine pref-page, about toolbox: add link to stats
In the preference page, in the 'about' toolbox of an engine, add a link to the stats page of the engine, if the engine had one or more errors. Condition is:: reliabilities[<engine.name>].errors Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
This commit is contained in:
parent
34bced29ae
commit
8026ed0d37
2 changed files with 17 additions and 6 deletions
|
@ -12,6 +12,11 @@
|
|||
{%- if stats[search_engine.name]['result_count'] -%}
|
||||
<p>{{ _('Number of results') }}: {{ stats[search_engine.name]['result_count'] }} ( {{ _('Avg.') }} )</p>{{- "" -}}
|
||||
{%- endif -%}
|
||||
{%- if reliabilities[search_engine.name].errors -%}
|
||||
<a href="{{ url_for('stats', engine=search_engine.name|e) }}" title="{{ _('View error logs and submit a bug report') }}">
|
||||
{{ _('View error logs and submit a bug report') }}
|
||||
</a>
|
||||
{%- endif -%}
|
||||
</div>
|
||||
{%- endif -%}
|
||||
{%- endmacro %}
|
||||
|
|
|
@ -25,6 +25,12 @@
|
|||
<p><a href="{{about.website}}" rel="noreferrer">{{about.website}}</a></p>
|
||||
{%- if about.wikidata_id -%}<p><a href="https://www.wikidata.org/wiki/{{about.wikidata_id}}" rel="noreferrer">wikidata.org/wiki/{{about.wikidata_id}}</a></p>{%- endif -%}
|
||||
{%- if search_engine.enable_http %}<p>{{ icon('exclamation-sign', 'No HTTPS') }}{{ _('No HTTPS')}}</p>{% endif -%}
|
||||
{%- if reliabilities[search_engine.name].errors -%}
|
||||
<a href="{{ url_for('stats', engine=search_engine.name|e) }}" title="{{ _('View error logs and submit a bug report') }}">
|
||||
{{ _('View error logs and submit a bug report') }}
|
||||
</a>
|
||||
{%- endif -%}
|
||||
|
||||
</div>
|
||||
{%- endif -%}
|
||||
{%- endmacro %}
|
||||
|
|
Loading…
Reference in a new issue