| 1 | {% comment %} |
| 2 | # SPDX-License-Identifier: AGPL-3.0-or-later |
| 3 | {% endcomment %} |
| 4 | |
| 5 | {% load i18n %} |
| 6 | |
| 7 | <div class="table-responsive"> |
| 8 | <table class="table diagnostics-results"> |
| 9 | <thead> |
| 10 | <tr> |
| 11 | <th class="diagnostic-test">{% trans "Test" %}</th> |
| 12 | <th class="diagnostics-result">{% trans "Result" %}</th> |
| 13 | </tr> |
| 14 | </thead> |
| 15 | <tbody> |
| 16 | {% for result in results %} |
| 17 | <tr> |
| 18 | <td>{{ result.translated_description }}</td> |
| 19 | <td class="diagnostics-result"> |
| 20 | {% if result.result == 'passed' %} |
| 21 | <span class="badge text-bg-success">{% trans result.result %}</span> |
| 22 | {% elif result.result == 'failed' %} |
| 23 | <span class="badge text-bg-danger">{% trans result.result %}</span> |
| 24 | {% elif result.result == 'error' or result.result == 'warning' %} |
| 25 | <span class="badge text-bg-warning">{% trans result.result %}</span> |
| 26 | {% elif result.result == 'skipped' %} |
| 27 | <span class="badge text-bg-secondary">{% trans result.result %}</span> |
| 28 | {% else %} |
| 29 | {{ result.result }} |
| 30 | {% endif %} |
| 31 | </td> |
| 32 | </tr> |
| 33 | {% endfor %} |
| 34 | </tbody> |
| 35 | </table> |
| 36 | </div> |