{# @var group \EasyCorp\Bundle\EasyAdminBundle\Dto\ActionGroupDto #} {# @var entity \EasyCorp\Bundle\EasyAdminBundle\Dto\EntityDto #} {% set has_main_action = group.hasMainAction %} {% set main_action = group.mainAction %}
{% if has_main_action %} {# render as a split button (main button with action + dropdown toggle) #} v is not null) }} > {% set main_action_label = main_action.label|trans %} {%- if main_action_label is not same as(false) -%}{{ main_action_label|raw }}{%- endif -%} {% else %} {# render as a single button that toggles the dropdown (no main action) #} {% endif %} {% for item in group.items %} {% if item is iterable and item.type is defined %} {% if item.type == 'divider' %} {% elseif item.type == 'header' %} {% set item_label = item.content|trans %} {% endif %} {% else %} {# item is an ActionDto #} {% endif %} {% endfor %}