EasyAdminBundle
EasyAdminBundle copied to clipboard
Trying to retrieve current entity name in an overrided twig template
Hello!
I'm trying to retrieve the current entity name in the layout.html.twig file I override. Before the update I was using "_entity.name" and it worked, but it doesn't work anymore. If possible I want to retrieve it in string format to compare it with an other string (with {{ 'expression' in 'string' }}).
Thanks in advance!
Nevermind, I solved the issue! Can be useful so I give here the solution: app.request.get('entity') to retrieve entity name in string format
Look at this example , you can get it with the _entity_config var
In fact this is what I used, sort of, thanks!