{% load i18n wagtailadmin_tags %}
{% if self.help_text %}
{{ self.help_text }}
{% endif %}
{% if classifier_groups %}

{% trans "Available Classifiers" %}

{% for group in classifier_groups %} {% comment %}Calculate selected count for this group{% endcomment %} {% with selected_count=0 %} {% for classifier in group.classifiers.all %} {% for child_form in self.formset %} {% if child_form.instance.classifier.id == classifier.id %} {% with selected_count=selected_count|add:1 %}{% endwith %} {% endif %} {% endfor %} {% endfor %}
0 %}style="display: block;"{% else %}style="display: none;"{% endif %}> {% for classifier in group.classifiers.all %}
{% endfor %}
{% endwith %} {% endfor %}
{% endif %}
{{ self.formset.management_form }}
{% for child_form in self.formset %}
{% for field in child_form %} {{ field.as_hidden }} {% endfor %}
{% endfor %}