diff --git a/templates/servers/detail.twig b/templates/servers/detail.twig index cfa8828..ffd74c8 100755 --- a/templates/servers/detail.twig +++ b/templates/servers/detail.twig @@ -108,31 +108,33 @@
{% for metricName, metricData in metrics %} -
-
-
-
- {{ metricName|replace({'_': ' ', 'load': 'загрузка', 'used': 'использование'})|title }} - {% if metricData[0].unit %}({{ metricData[0].unit }}){% endif %} -
-
-
- {% if metricData %} -

{{ metricData[0].value }}{{ metricData[0].unit|default('') }}

-

- {{ metricData[0].created_at|date('d.m.Y H:i:s') }} -

+ {% if metricName!="top_cpu_proc" && metricName!="top_ram_proc" %} +
+
+
+
+ {{ metricName|replace({'_': ' ', 'load': 'загрузка', 'used': 'использование'})|title }} + {% if metricData[0].unit %}({{ metricData[0].unit }}){% endif %} +
+
+
+ {% if metricData %} +

{{ metricData[0].value }}{{ metricData[0].unit|default('') }}

+

+ {{ metricData[0].created_at|date('d.m.Y H:i:s') }} +

- -
- -
- {% else %} -

Нет данных за этот период

- {% endif %} + +
+ +
+ {% else %} +

Нет данных за этот период

+ {% endif %} +
-
+ {% endif %} {% endfor %} {% if metrics|length == 0 %} @@ -464,6 +466,7 @@ document.addEventListener('DOMContentLoaded', function() { // Графики метрик {% for metricName, metricData in metrics %} +{% if metricName!="top_cpu_proc" && metricName!="top_ram_proc" %} const ctx{{ metricName|replace({'-': '_', '.': '_'}) }} = document.getElementById('chart-{{ metricName }}').getContext('2d'); // Подготовка данных для графика @@ -573,6 +576,7 @@ new Chart(ctx{{ metricName|replace({'-': '_', '.': '_'}) }}, { } } }); +{% endif %} {% endfor %} {% endblock %}