diff --git a/plinth/modules/diagnostics/templates/diagnostics_module.html b/plinth/modules/diagnostics/templates/diagnostics_module.html index 8e9ac2462..aa17bff1b 100644 --- a/plinth/modules/diagnostics/templates/diagnostics_module.html +++ b/plinth/modules/diagnostics/templates/diagnostics_module.html @@ -25,28 +25,9 @@

Module: {{ module_name }}

{% if results %} -
-
- - - - - - - - - {% for test, result in results %} - - - - - {% endfor %} - -
TestResult
{{ test }}{{ result }}
-
-
+ {% include "diagnostics_results.html" with results=results %} {% else %} -

This module does not support diagnostics

+

This module does not support diagnostics

{% endif %} {% endblock %} diff --git a/plinth/modules/diagnostics/templates/diagnostics_results.html b/plinth/modules/diagnostics/templates/diagnostics_results.html new file mode 100644 index 000000000..b8b59069c --- /dev/null +++ b/plinth/modules/diagnostics/templates/diagnostics_results.html @@ -0,0 +1,50 @@ +{% comment %} +# +# This file is part of Plinth. +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU Affero General Public License as +# published by the Free Software Foundation, either version 3 of the +# License, or (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Affero General Public License for more details. +# +# You should have received a copy of the GNU Affero General Public License +# along with this program. If not, see . +# +{% endcomment %} + +
+
+ + + + + + + + + {% for test, result in results %} + + + + + {% endfor %} + +
TestResult
{{ test }} + {% if result == 'passed' %} + {{ result }} + {% elif result == 'failed' %} + {{ result }} + {% elif result == 'error' %} + {{ result }} + {{ result }} + {% else %} + {{ result }} + {% endif %} +
+
+
diff --git a/static/themes/default/css/plinth.css b/static/themes/default/css/plinth.css index 09f0bbeb0..a29aea31d 100644 --- a/static/themes/default/css/plinth.css +++ b/static/themes/default/css/plinth.css @@ -42,3 +42,7 @@ body { .no-js .nav .dropdown .caret { display: none; } + +.diagnostics-results .diagnostics-result { + width: 60px; +}