{% if form is defined %}
  {% form_theme form with ['@AutoAdminAdmin/form/form_theme.html.twig', '@AutoAdminMedia/Form/fields.html.twig'] %}
{% endif %}

{% if menuItemId is defined and menuItemId is not empty and item is defined and item is not empty %}
  {{ form_start(form, {action: admin_path(item, 'update', {menuId: menuId}) }) }}
{% else %}
  {{ form_start(form, {action: admin_path(item, 'create', {menuId: menuId}) }) }}
{% endif %}
{{ form_widget(form) }}
<button type="submit" class="btn btn-primary">{{ 'submit'|trans({}, 'aa_admin') }}</button>
{{ form_end(form) }}