mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-14 14:24:24 +00:00
dynamic back message in return values
This commit is contained in:
parent
3c434852d5
commit
835ead6ccd
@ -18,7 +18,7 @@ Moderator: Animateur
|
|||||||
Details of an event: Détails d'un événement
|
Details of an event: Détails d'un événement
|
||||||
New event: Nouvel événement
|
New event: Nouvel événement
|
||||||
Back to the most recent events: Retour aux derniers événements
|
Back to the most recent events: Retour aux derniers événements
|
||||||
Back to the person events: Retour aux événements de la personne
|
'Back to %person% events': Retour aux événements de %person%
|
||||||
Event creation: Création d'un événement
|
Event creation: Création d'un événement
|
||||||
Add an event: Ajouter un événement
|
Add an event: Ajouter un événement
|
||||||
Event edit: Modifier un événement
|
Event edit: Modifier un événement
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
{% extends "ChillPersonBundle::layout.html.twig" %}
|
{% extends "ChillPersonBundle::layout.html.twig" %}
|
||||||
|
|
||||||
{% set activeRouteKey = 'chill_event__list_by_person' %}
|
{% set activeRouteKey = 'chill_event__list_by_person' %}
|
||||||
|
{% set currentPerson = person.firstName ~ ' ' ~ person.lastName %}
|
||||||
|
|
||||||
{% block title %}{{ 'Events participation' |trans }}{% endblock title %}
|
{% block title %}{{ 'Events participation' |trans }}{% endblock title %}
|
||||||
|
|
||||||
@ -46,7 +47,7 @@
|
|||||||
<ul class="record_actions">
|
<ul class="record_actions">
|
||||||
<li>
|
<li>
|
||||||
{% set currentPath = path(app.request.attributes.get('_route'), app.request.attributes.get('_route_params')) %}
|
{% set currentPath = path(app.request.attributes.get('_route'), app.request.attributes.get('_route_params')) %}
|
||||||
{% set returnLabel = 'Back to the person events'|trans %}
|
{% set returnLabel = 'Back to %person% events'|trans({ '%person%' : currentPerson } ) %}
|
||||||
|
|
||||||
{# temporaire --
|
{# temporaire --
|
||||||
TODO corriger EventVoter.php pour régler les autorisations sur les boutons, puis remplacer ci-dessous par le code commenté #}
|
TODO corriger EventVoter.php pour régler les autorisations sur les boutons, puis remplacer ci-dessous par le code commenté #}
|
||||||
@ -84,7 +85,7 @@
|
|||||||
'event_id' : participation.event.id,
|
'event_id' : participation.event.id,
|
||||||
'return_path' : currentPath,
|
'return_path' : currentPath,
|
||||||
'return_label' : returnLabel
|
'return_label' : returnLabel
|
||||||
} ) }}" class="sc-button bt-show"></a>
|
} ) }}" class="sc-button bt-show"></a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if is_granted('CHILL_EVENT_UPDATE', participation.event)
|
{% if is_granted('CHILL_EVENT_UPDATE', participation.event)
|
||||||
@ -145,7 +146,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{#
|
{#
|
||||||
#}
|
|
||||||
{{ dump() }}
|
{{ dump() }}
|
||||||
|
#}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
@ -34,8 +34,10 @@
|
|||||||
</table>
|
</table>
|
||||||
|
|
||||||
<ul class="record_actions">
|
<ul class="record_actions">
|
||||||
|
|
||||||
{% set returnPath = app.request.get('return_path') %}
|
{% set returnPath = app.request.get('return_path') %}
|
||||||
{% set returnLabel = app.request.get('return_label') %}
|
{% set returnLabel = app.request.get('return_label') %}
|
||||||
|
|
||||||
{% if returnPath and returnLabel %}
|
{% if returnPath and returnLabel %}
|
||||||
<li class="cancel">
|
<li class="cancel">
|
||||||
<a href="{{ returnPath }}" class="sc-button bt-cancel">{{ returnLabel }}</a>
|
<a href="{{ returnPath }}" class="sc-button bt-cancel">{{ returnLabel }}</a>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user