summaryrefslogtreecommitdiffstats
path: root/ogcp/templates
diff options
context:
space:
mode:
authorJavier Sánchez Parra <jsanchez@soleta.eu>2022-02-23 17:11:17 +0100
committerJavier Sánchez Parra <jsanchez@soleta.eu>2022-02-24 17:05:29 +0100
commit23d9799e09ea6192fb12d6091e31400fbd6c3a8d (patch)
treea29789a90f9981862d975d2a612e455fb1b3d145 /ogcp/templates
parentaf4b07cecf032ed4812eb0af288a00a966eb36d1 (diff)
Limit max number of clients drawn in commands
Print large number of clients (hundreds) does not make sense, it is unreadable.
Diffstat (limited to 'ogcp/templates')
-rw-r--r--ogcp/templates/macros.html6
1 files changed, 5 insertions, 1 deletions
diff --git a/ogcp/templates/macros.html b/ogcp/templates/macros.html
index a779dd7..d6ef2af 100644
--- a/ogcp/templates/macros.html
+++ b/ogcp/templates/macros.html
@@ -55,8 +55,12 @@
{% macro cmd_selected_clients(ip_list) -%}
<ul class="list-group mx-5 list-group-horizontal-sm d-flex flex-wrap">
-{% for ip in ip_list %}
+{% set max_clients = 50 %}
+{% for ip in ip_list[:max_clients] %}
<li class="list-group-item flex-fill list-group-item-info">{{ ip }}</li>
+ {% if loop.last %}
+ <li class="list-group-item flex-fill list-group-item-info">...</li>
+ {% endif %}
{% endfor %}
</ul>
{% endmacro %}