mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 15:13:50 +00:00
OnTheFly: adding displayBadge option to replace button by badge
When using displayBadge=true, you need to pass buttonText=string with badge content. Limitation: onTheFly cannot use directly PersonRenderBox to display badge, because it don't have person object in props !
This commit is contained in:
@@ -1,17 +0,0 @@
|
||||
{% for p in accompanyingCourse.participations %}
|
||||
|
||||
{#
|
||||
<span class="badge-person">
|
||||
<a href="{{ path('chill_person_view', { 'person_id': p.person.id }) }}"
|
||||
title="{{ p.person.firstName ~ ' ' ~ p.person.lastName }}">
|
||||
{{ p.person|chill_entity_render_box }}
|
||||
</a>
|
||||
</span>
|
||||
#}
|
||||
|
||||
A
|
||||
{# include vue_onthefly component #}
|
||||
{% include '@ChillMain/OnTheFly/_insert_vue_onthefly.html.twig' with { targetEntity: { name: 'person', id: p.person.id }, action: 'show' } %}
|
||||
|
||||
{% endfor %}
|
||||
|
@@ -24,7 +24,17 @@
|
||||
<div class="accompanyingcourse-resume row">
|
||||
|
||||
<div class="concerned mb-5">
|
||||
{% include '@ChillPerson/AccompanyingCourse/_concerned.html.twig' with {} %}
|
||||
{% for p in accompanyingCourse.participations %}
|
||||
|
||||
{# include vue_onthefly component #}
|
||||
{% include '@ChillMain/OnTheFly/_insert_vue_onthefly.html.twig' with {
|
||||
targetEntity: { name: 'person', id: p.person.id },
|
||||
action: 'show',
|
||||
displayBadge: true,
|
||||
buttonText: p.person|chill_entity_render_string
|
||||
} %}
|
||||
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
<div class="col-md-6 location mb-5">
|
||||
|
Reference in New Issue
Block a user