vendor/easycorp/easyadmin-bundle/src/Resources/views/crud/edit.html.twig line 1

Open in your IDE?
  1. {# @var ea \EasyCorp\Bundle\EasyAdminBundle\Context\AdminContext #}
  2. {# @var entity \EasyCorp\Bundle\EasyAdminBundle\Dto\EntityDto #}
  3. {% extends ea.templatePath('layout') %}
  4. {% form_theme edit_form with ea.crud.formThemes only %}
  5. {% trans_default_domain ea.i18n.translationDomain %}
  6. {% block body_id 'ea-edit-' ~ entity.name ~ '-' ~ entity.primaryKeyValue %}
  7. {% block body_class 'ea-edit ea-edit-' ~ entity.name %}
  8. {% block configured_head_contents %}
  9.     {{ parent() }}
  10.     {% for htmlContent in edit_form.vars.ea_crud_form.assets.headContents %}
  11.         {{ htmlContent|raw }}
  12.     {% endfor %}
  13. {% endblock %}
  14. {% block configured_body_contents %}
  15.     {{ parent() }}
  16.     {% for htmlContent in edit_form.vars.ea_crud_form.assets.bodyContents %}
  17.         {{ htmlContent|raw }}
  18.     {% endfor %}
  19. {% endblock %}
  20. {% block configured_stylesheets %}
  21.     {{ parent() }}
  22.     {{ include('@EasyAdmin/includes/_css_assets.html.twig', { assets: edit_form.vars.ea_crud_form.assets.cssAssets }, with_context = false) }}
  23.     {{ include('@EasyAdmin/includes/_encore_link_tags.html.twig', { assets: edit_form.vars.ea_crud_form.assets.webpackEncoreAssets }, with_context = false) }}
  24. {% endblock %}
  25. {% block configured_javascripts %}
  26.     {{ parent() }}
  27.     {{ include('@EasyAdmin/includes/_js_assets.html.twig', { assets: edit_form.vars.ea_crud_form.assets.jsAssets }, with_context = false) }}
  28.     {{ include('@EasyAdmin/includes/_encore_script_tags.html.twig', { assets: edit_form.vars.ea_crud_form.assets.webpackEncoreAssets }, with_context = false) }}
  29. {% endblock %}
  30. {% block content_title %}
  31.     {%- apply spaceless -%}
  32.         {% set custom_page_title = ea.crud.customPageTitle(pageName, entity ? entity.instance : null) %}
  33.         {{ custom_page_title is null
  34.             ? (ea.crud.defaultPageTitle|trans(ea.i18n.translationParameters, 'EasyAdminBundle'))|raw
  35.             : (custom_page_title|trans(ea.i18n.translationParameters))|raw }}
  36.     {%- endapply -%}
  37. {% endblock %}
  38. {% block page_actions %}
  39.     {% for action in entity.actions %}
  40.         {{ include(action.templatePath, { action: action }, with_context = false) }}
  41.     {% endfor %}
  42. {% endblock %}
  43. {% block main %}
  44.     {% block edit_form %}
  45.         {{ form(edit_form) }}
  46.     {% endblock edit_form %}
  47.     {% block delete_form %}
  48.         {{ include('@EasyAdmin/crud/includes/_delete_form.html.twig', { entity_id: entity.primaryKeyValue }, with_context = false) }}
  49.     {% endblock delete_form %}
  50. {% endblock %}