summaryrefslogtreecommitdiff
path: root/searx/templates/oscar/preferences.html
diff options
context:
space:
mode:
authorAlexandre Flament <alex@al-f.net>2021-04-30 11:49:39 +0200
committerAlexandre Flament <alex@al-f.net>2021-05-04 10:50:03 +0200
commite83862c22f17295b8d493240cd0c51d25d1c59f9 (patch)
tree068d1a812ea9544272b12e73f5539e23d474f682 /searx/templates/oscar/preferences.html
parente5bcc3cbbecb067b0acd8a7c061d9a16453381ed (diff)
[themes] /preferences, reliablity: warning icons & error logs link
When there is at least one errors or one failed checker test: * the warning icon is displayed in the reliability column * the link "View error logs and submit a bug report" is displayed on engine name tooltip. Before: * the warning icon was displayed only when one or more checker test(s) failed. * the link "View error logs and submit a bug report" was not shown when a checker test failed but there were no error.
Diffstat (limited to 'searx/templates/oscar/preferences.html')
-rw-r--r--searx/templates/oscar/preferences.html8
1 files changed, 4 insertions, 4 deletions
diff --git a/searx/templates/oscar/preferences.html b/searx/templates/oscar/preferences.html
index 3f113afec..33fb41061 100644
--- a/searx/templates/oscar/preferences.html
+++ b/searx/templates/oscar/preferences.html
@@ -12,7 +12,7 @@
{%- 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 -%}
+ {%- if reliabilities.get(search_engine.name, {}).errors or reliabilities.get(search_engine.name, {}).checker -%}
<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>
@@ -56,11 +56,11 @@
{% if checker_result or errors %}
<td class="{{ css_align_class }} {{ label }}">{{- "" -}}
<a href="{{ url_for('stats', engine=engine_name|e) }}">{{- "" -}}
- <span aria-labelledby="{{engine_name}}_reliablity">
- {%- if reliabilities[engine_name].checker %}{{ icon('exclamation-sign', 'The checker fails on the some tests') }}{% endif %} {{ r -}}</a>
+ <span aria-labelledby="{{engine_name}}_reliability">
+ {{ icon('exclamation-sign', 'The engine is not reliabled') }} {{ r -}}
</span>{{- "" -}}
</a>{{- "" -}}
- <div class="engine-tooltip text-left" role="tooltip" id="{{engine_name}}_reliablity">
+ <div class="engine-tooltip text-left" role="tooltip" id="{{engine_name}}_reliability">
{%- if checker_result -%}
<p>{{ _("Failed checker test(s): ") }} {{ ', '.join(checker_result) }}</p>
{%- endif -%}