{% extends '@HeimrichHannotTwigTemplates/forms/form_row_bs4.html.twig' %} {% set optionGroupClass = "checkbox-group ctrl_" ~ strId %} {% set wrapperTag = "fieldset" %} {% if arrOptions|length == 1 and not arrConfiguration.multiple|default(false) %} {% set option = arrOptions[0] %} {% set option = option|merge({label: strLabel}) %} {% if arrConfiguration.mandatory|default(false) %} {% set option = option|merge({label: option.label ~ '*'}) %} {% endif %} {% set arrOptions = [option] %} {% endif %} {% block label %} {% if(not arrConfiguration.hideLabel|default(false) and (arrOptions|default([])|length > 1 or arrConfiguration.multiple|default(false))) %} {{ strLabel|raw }} {% if arrConfiguration.mandatory|default(false) %} * {% endif %} {% endif %} {% endblock %} {% block field %}
{% for option in arrOptions %} {% set counter = random() %} {% block option %}
{% if loop.last and not arrConfiguration.inline|default(false)%} {% if(hasErrors|default(false) and errorsAsString|default()) %}
{{ errorsAsString|raw }}
{% endif %} {% endif %}
{% endblock %} {% endfor %}
{% endblock %} {% block feedback %} {% if arrConfiguration.inline|default(false) %} {% set formFeedbackClass = formFeedbackClass|merge(['d-block']) %} {{ parent() }} {% endif %} {% endblock %}