{% set noresult = true %}
{% for user_cluster in f_clusters(0) %}
{% set noresult = false %}
{% set id_user_cluster = 'u' ~ user_cluster.id_user_cluster %}
{% set memlen = f_members(user_cluster.id_user_cluster,0) | length %}
{{ user_cluster.name }}
{{ p_icon.remove | raw }}
{{ p_icon.edit | raw }}
{{ p_icon.user | raw }}
{{ memlen }} utilisateur{% if memlen > 1 %}s{% endif %}
{{ p_icon.group | raw }}
{% for user in f_members(user_cluster.id_user_cluster, 0) %}
{{ user.username }}
{% endfor %}
+
{% endfor %}
{% for machine_cluster in f_clusters(1) %}
{% set noresult = false %}
{% set id_machine_cluster = 'm' ~ machine_cluster.id_machine_cluster %}
{% set memlen = f_members(machine_cluster.id_machine_cluster,1) | length %}
{{ machine_cluster.name }}
{{ p_icon.remove | raw }}
{{ p_icon.edit | raw }}
{{ p_icon.device | raw }}
{{ memlen }} machine{% if memlen > 1 %}s{% endif %}
{{ p_icon.option | raw }}
{% for option in f_options(machine_cluster.id_machine_cluster) %}
{{ option.name }}:{{ option.daemon }}
{% else %}
Aucune option
{% endfor %}
{{ p_icon.group | raw }}
{% for machine in f_members(machine_cluster.id_machine_cluster,1) %}
{{ machine.name }}
{% endfor %}
+
{% endfor %}
{# if no result #}
{% if noresult %}
Aucun groupe trouvé
{% endif %}