use entity_render_string in titles

This commit is contained in:
Julien Fastré 2021-10-11 14:52:51 +02:00
parent 2db9a98bfe
commit b5394a3de2
2 changed files with 3 additions and 4 deletions

View File

@ -18,12 +18,12 @@
{% set activeRouteKey = '' %} {% set activeRouteKey = '' %}
{% block title %}{{ 'Update details for %name%'|trans({ '%name%': person.firstName|capitalize ~ ' ' ~ person.lastName } )|capitalize }}{% endblock %} {% block title %}{{ 'Update details for %name%'|trans({ '%name%': person|chill_entity_render_string } ) }}{% endblock %}
{% block personcontent %} {% block personcontent %}
<div class="person-edit"> <div class="person-edit">
<h1>{{ 'Update details for %name%'|trans({ '%name%': person.firstName|capitalize ~ ' ' ~ person.lastName|capitalize } ) }}</h1> <h1>{{ block('title') }}</h1>
{% form_theme form '@ChillMain/Form/fields.html.twig' %} {% form_theme form '@ChillMain/Form/fields.html.twig' %}
{{ form_start(form) }} {{ form_start(form) }}

View File

@ -23,8 +23,7 @@ This view should receive those arguments:
- person - person
#} #}
{% block title %}{{ 'Person details'|trans|capitalize ~ ' ' ~ person.firstName|capitalize ~ {% block title %}{{ 'Person details'|trans|capitalize ~ ' ' ~ person|chill_entity_render_string }}{% endblock %}
' ' ~ person.lastName }}{% endblock %}
{# {#
we define variables to include an edit form repeated multiple time across we define variables to include an edit form repeated multiple time across
the page the page