Show userGroup in workflow breadcrumb

related:

- https://champs-libres.openproject.com/wp/774
- OP#774
- Vendee/accent-suivi-developpement#1274
This commit is contained in:
Julien Fastré 2024-10-24 16:15:49 +02:00
parent bf85e9bb71
commit f750cfecac
Signed by: julienfastre
GPG Key ID: BDE2190974723FCB
2 changed files with 7 additions and 5 deletions

View File

@ -42,7 +42,7 @@
<div class="item-col" style="width: inherit;"> <div class="item-col" style="width: inherit;">
<div> <div>
{%- if step.transitionBy is not null -%} {%- if step.transitionBy is not null -%}
{{ step.transitionBy|chill_entity_render_box({'at_date': step.transitionAt}) }} <span class="badge-user">{{ step.transitionBy|chill_entity_render_box({'at_date': step.transitionAt}) }}</span>
{% else %} {% else %}
<span class="chill-no-data-statement">{{ 'workflow.Automated transition'|trans }}</span> <span class="chill-no-data-statement">{{ 'workflow.Automated transition'|trans }}</span>
{%- endif -%} {%- endif -%}
@ -105,7 +105,7 @@
<p><b>{{ 'workflow.Users put in Cc'|trans }}&nbsp;: </b></p> <p><b>{{ 'workflow.Users put in Cc'|trans }}&nbsp;: </b></p>
<ul> <ul>
{% for u in step.ccUser %} {% for u in step.ccUser %}
<li>{{ u|chill_entity_render_box({'at_date': step.previous.transitionAt}) }}</li> <li><span class="badge-user">{{ u|chill_entity_render_box({'at_date': step.previous.transitionAt}) }}</span></li>
{% endfor %} {% endfor %}
</ul> </ul>
{% endif %} {% endif %}
@ -123,7 +123,7 @@
<p><b>{{ 'workflow.Those users are also granted to apply a transition by using an access key'|trans }}&nbsp;:</b></p> <p><b>{{ 'workflow.Those users are also granted to apply a transition by using an access key'|trans }}&nbsp;:</b></p>
<ul> <ul>
{% for u in step.destUserByAccessKey %} {% for u in step.destUserByAccessKey %}
<li>{{ u|chill_entity_render_box({'at_date': step.previous.transitionAt}) }}</li> <li><span class="badge-user">{{ u|chill_entity_render_box({'at_date': step.previous.transitionAt}) }}</span></li>
{% endfor %} {% endfor %}
</ul> </ul>
{% endif %} {% endif %}

View File

@ -9,11 +9,13 @@
<span class="item-key">{{ 'Le'|trans ~ ' : ' }}</span> <span class="item-key">{{ 'Le'|trans ~ ' : ' }}</span>
<b>{{ step.previous.transitionAt|format_datetime('short', 'short') }}</b> <b>{{ step.previous.transitionAt|format_datetime('short', 'short') }}</b>
</li> </li>
{% if step.destUser|length > 0 %} {% if step.destUser|length > 0 or step.destUserGroups|length > 0 %}
<li> <li>
<span class="item-key">{{ 'workflow.For'|trans ~ ' : ' }}</span> <span class="item-key">{{ 'workflow.For'|trans ~ ' : ' }}</span>
<b> <b>
{% for d in step.destUser %}{{ d|chill_entity_render_string({'at_date': step.previous.transitionAt}) }}{% if not loop.last %}, {% endif %}{% endfor %} {% for d in step.destUser %}<span class="badge-user">{{ d|chill_entity_render_string({'at_date': step.previous.transitionAt}) }}</span>{% if not loop.last %}, {% endif -%}{% endfor -%}
{%- if step.destUser|length > 0 and step.destUserGroups|length > 0 %}, {% endif -%}
{%- for d in step.destUserGroups %}{{ d|chill_entity_render_box }}{% if not loop.last %}, {% endif %}{% endfor -%}
</b> </b>
</li> </li>
{% endif %} {% endif %}