templates/admin/fields/BewerkTabField.html.twig line 1

Open in your IDE?
  1. {# @var ea \EasyCorp\Bundle\EasyAdminBundle\Context\AdminContext #}
  2. {# @var field \EasyCorp\Bundle\EasyAdminBundle\Dto\FieldDto #}
  3. {# @var entity \EasyCorp\Bundle\EasyAdminBundle\Dto\EntityDto #}
  4. {% if ea.crud.currentAction == 'detail' %}
  5. {% set url = ea_url()
  6.                 .setController("App\\Controller\\Admin\\Order\\Partial\\Tab#{field.value|capitalize}Controller")
  7.                 .setAction('edit')
  8.                 .set('entityId',field.formattedValue.entityId)
  9.                 .set('tab', field.value|lower)
  10.                 .set('parentControllerFqcn',ea.getRequest().get('crudControllerFqcn'))
  11.                 .generateUrl()
  12. %}
  13.         <div><p class="text-end">
  14.                 <a class=" btn btn-sm btn-primary " href="{{ url }}"> <span class="action-label">Bewerk dit tabblad</span>
  15.             </a>
  16.             </p>
  17.         </div>
  18.     {#</div>#}
  19. {% else %}
  20.     <span title="Message">"Use only on Detailpage"</span>
  21. {% endif %}<br>