diff --git a/src/Bundle/ChillActivityBundle/Resources/views/Activity/concernedGroups.html.twig b/src/Bundle/ChillActivityBundle/Resources/views/Activity/concernedGroups.html.twig
index 2808cca60..d6d0ed43d 100644
--- a/src/Bundle/ChillActivityBundle/Resources/views/Activity/concernedGroups.html.twig
+++ b/src/Bundle/ChillActivityBundle/Resources/views/Activity/concernedGroups.html.twig
@@ -3,6 +3,14 @@
{{ path(pathname, parms) }}
{% endmacro %}
+{% macro insert_onthefly(type, entity) %}
+ {% include '@ChillMain/OnTheFly/_insert_vue_onthefly.html.twig' with {
+ action: 'show', displayBadge: true,
+ targetEntity: { name: type, id: entity.id },
+ buttonText: entity|chill_entity_render_string
+ } %}
+{% endmacro %}
+
{% macro computeWidth(nbBlocks) %}
{{ 'flex-basis: ' ~ (100 / nbBlocks)|round(1) ~ '%;' }}
{% endmacro %}
@@ -13,6 +21,7 @@
{% set blocks = blocks|merge([{
'title': 'Others persons'|trans,
'items': entity.persons,
+ 'type': 'person',
'path' : 'chill_person_view',
'key' : 'person_id'
}]) %}
@@ -20,11 +29,13 @@
{% set blocks = blocks|merge([{
'title': 'Persons in accompanying course'|trans,
'items': entity.personsAssociated,
+ 'type': 'person',
'path' : 'chill_person_view',
'key' : 'person_id'
},{
'title': 'Third persons'|trans,
'items': entity.personsNotAssociated,
+ 'type': 'person',
'path' : 'chill_person_view',
'key' : 'person_id',
}]) %}
@@ -34,6 +45,7 @@
{% set blocks = blocks|merge([{
'title': 'Third parties'|trans,
'items': entity.thirdParties,
+ 'type': 'thirdparty',
'path' : 'chill_crud_3party_3party_view',
'key' : 'id',
}]) %}
@@ -42,6 +54,7 @@
{% set blocks = blocks|merge([{
'title': 'Users concerned'|trans,
'items': entity.users,
+ 'type': 'user',
'key' : 'id',
}]) %}
{% endif %}
@@ -59,22 +72,12 @@
{% for item in bloc.items %}
-
- {% if bloc.path is defined %}
-
-
- {{ item|chill_entity_render_box({
- 'render': 'raw',
- 'addAltNames': false
- }) }}
+ {% if bloc.type == 'user' %}
+
+ {{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false }) }}
-
{% else %}
-
- {{ item|chill_entity_render_box({
- 'render': 'raw',
- 'addAltNames': false
- }) }}
-
+ {{ _self.insert_onthefly(bloc.type, item) }}
{% endif %}
{% endfor %}
@@ -96,20 +99,12 @@
{% for item in bloc.items %}
-
- {% if bloc.path is defined %}
-
-
- {{ item|chill_entity_render_box({
- 'render': 'raw',
- 'addAltNames': false
- }) }}
+ {% if bloc.type == 'user' %}
+
+ {{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false }) }}
-
{% else %}
- {{ item|chill_entity_render_box({
- 'render': 'raw',
- 'addAltNames': false
- }) }}
+ {{ _self.insert_onthefly(bloc.type, item) }}
{% endif %}
{% endfor %}
@@ -131,19 +126,13 @@
{% for item in bloc.items %}
-
- {% if bloc.path is defined %}
-
- {{ item|chill_entity_render_box({
- 'render': 'raw',
- 'addAltNames': false
- }) }}
-
+
+ {% if bloc.type == 'user' %}
+
+ {{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false }) }}
+
{% else %}
- {{ item|chill_entity_render_box({
- 'render': 'raw',
- 'addAltNames': false
- }) }}
+ {{ _self.insert_onthefly(bloc.type, item) }}
{% endif %}
diff --git a/src/Bundle/ChillPersonBundle/Resources/public/chill/scss/badge.scss b/src/Bundle/ChillPersonBundle/Resources/public/chill/scss/badge.scss
index acf19205f..b1a06876a 100644
--- a/src/Bundle/ChillPersonBundle/Resources/public/chill/scss/badge.scss
+++ b/src/Bundle/ChillPersonBundle/Resources/public/chill/scss/badge.scss
@@ -2,6 +2,7 @@
* BADGES PERSON AND THIRDPARTY
*/
+span.badge-user,
span.badge-person,
span.badge-thirdparty {
display: inline-block;
@@ -16,6 +17,10 @@ span.badge-thirdparty {
text-decoration: none;
}
}
+
+span.badge-user {
+ border-bottom-width: 1px;
+}
span.badge-person {
border-bottom-color: $chill-green;
}