Исключение отображения графиков для метрик top_cpu_proc и top_ram_proc
This commit is contained in:
parent
26d659ae7d
commit
b60a092a2f
|
|
@ -108,6 +108,7 @@
|
|||
|
||||
<div class="row">
|
||||
{% for metricName, metricData in metrics %}
|
||||
{% if metricName!="top_cpu_proc" && metricName!="top_ram_proc" %}
|
||||
<div class="col-12 mb-4">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
|
|
@ -133,6 +134,7 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% 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 %}
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
|
|
|||
Loading…
Reference in New Issue