mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 15:13:50 +00:00
fix folder name
This commit is contained in:
@@ -0,0 +1,74 @@
|
||||
{% extends "@ChillPerson/layout.html.twig" %}
|
||||
|
||||
{% set activeRouteKey = null %}
|
||||
|
||||
{# define the title of the page #}
|
||||
{% if form.vars.action == 'update' %}
|
||||
{% set page_title = 'Update accompanying period'|trans %}
|
||||
{% elseif form.vars.action == 'open' %}
|
||||
{% set page_title = 'Update accompanying period'|trans %}
|
||||
{% elseif form.vars.action == 'close' %}
|
||||
{% set page_title = 'Update accompanying period'|trans %}
|
||||
{% elseif form.vars.action == 'create' %}
|
||||
{% set page_title = 'Create an accompanying period'|trans %}
|
||||
{% else %}
|
||||
{% set page_title = '' %}
|
||||
{% endif %}
|
||||
|
||||
{% block title page_title %}
|
||||
|
||||
|
||||
{% block personcontent %}
|
||||
|
||||
<h1>{{ page_title }}</h1>
|
||||
|
||||
{{ form_start(form) }}
|
||||
|
||||
<p>
|
||||
{{ 'Last opening since %last_opening%'|trans(
|
||||
{ '%last_opening%' : accompanying_period.openingDate|format_date('long') }) }}
|
||||
</p>
|
||||
|
||||
{% if form.openingDate is defined %}
|
||||
{{ form_row(form.openingDate, { 'label': 'Opening date'} ) }}
|
||||
{% endif %}
|
||||
{% if form.closingDate is defined %}
|
||||
{{ form_row(form.closingDate, {'label' : 'Closing date'} ) }}
|
||||
{% endif %}
|
||||
|
||||
{% if form.closingMotive is defined %}
|
||||
{{ form_row(form.closingMotive, {'label' : 'Closing motive'} ) }}
|
||||
{% endif %}
|
||||
|
||||
{% if form.user is defined %}
|
||||
{{ form_row(form.user, {'label': 'Accompanying user'}) }}
|
||||
{% endif %}
|
||||
|
||||
{{ form_row(form.remark, {'label' : 'Remark' } ) }}
|
||||
|
||||
{{ form_rest(form) }}
|
||||
|
||||
<ul class="record_actions sticky-form-buttons">
|
||||
<li class="cancel">
|
||||
<a href="{{ path('chill_person_accompanying_period_list', { 'person_id' : person.id } ) }}" class="sc-button bt-cancel">{{ 'Back to the list'|trans }}</a>
|
||||
</li>
|
||||
<li>
|
||||
<button type="submit" class="sc-button bt-save">
|
||||
{% if form.vars.action == 'update' %}
|
||||
{{ 'Update accompanying period'|trans }}
|
||||
{% elseif form.vars.action == 'open' %}
|
||||
{{ 'Update accompanying period'|trans }}
|
||||
{% elseif form.vars.action == 'close' %}
|
||||
{{'Close accompanying period'|trans }}
|
||||
{% elseif form.vars.action == 'create' %}
|
||||
{{ 'Create an accompanying period'|trans }}
|
||||
{% endif %}
|
||||
|
||||
</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
{{ form_end(form) }}
|
||||
|
||||
|
||||
{% endblock personcontent %}
|
@@ -0,0 +1,104 @@
|
||||
{% extends "@ChillPerson/layout.html.twig" %}
|
||||
|
||||
{% set activeRouteKey = 'chill_person_accompanying_period_list' %}
|
||||
|
||||
{% block title %}{{ 'Person accompanying period - %name%'|trans({ '%name%' : person.__toString}) }}{% endblock title %}
|
||||
|
||||
{% block personcontent %}
|
||||
<table class="rounded">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="chill-red">{{ 'accompanying_period.dates'|trans }}</th>
|
||||
{% if chill_accompanying_periods.fields.user == 'visible' %}
|
||||
<th class="chill-blue">{{ 'Accompanying user'|trans }}</th>
|
||||
{% endif %}
|
||||
<th class="chill-orange">{{ 'Remark'|trans }}</th>
|
||||
<th> </th>
|
||||
</tr>
|
||||
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for accompanying_period in accompanying_periods %}
|
||||
<tr>
|
||||
<td>
|
||||
{% if accompanying_period.closingDate == null %}
|
||||
{{ 'accompanying_period.dates_from_%opening_date%'|trans({ '%opening_date%': accompanying_period.openingDate|format_date('long') } ) }}
|
||||
{% else %}
|
||||
{{ 'accompanying_period.dates_from_%opening_date%_to_%closing_date%'|trans({
|
||||
'%opening_date%': accompanying_period.openingDate|format_date('long'),
|
||||
'%closing_date%': accompanying_period.closingDate|format_date('long')}
|
||||
) }}
|
||||
|
||||
{% if accompanying_period.isOpen == false %}
|
||||
<dl class="chill_view_data">
|
||||
<dt>{{ 'Closing motive'|trans }} :</dt>
|
||||
<dd>{{ accompanying_period.closingMotive|chill_entity_render_box }}</dd>
|
||||
</dl>
|
||||
{% endif %}
|
||||
|
||||
{% endif %}
|
||||
</td>
|
||||
{% if chill_accompanying_periods.fields.user == 'visible' %}
|
||||
<td>
|
||||
{% if accompanying_period.user %}
|
||||
{{ accompanying_period.user.username }}
|
||||
{% else %}
|
||||
<span class="chill-no-data-statement">{{ 'No accompanying user'|trans }}</span>
|
||||
{% endif %}
|
||||
</td>
|
||||
{% endif %}
|
||||
<td>
|
||||
|
||||
{{ accompanying_period.remark|chill_print_or_message('No remark', 'blockquote') }}
|
||||
</td>
|
||||
<td>
|
||||
<ul class="record_actions">
|
||||
<li>
|
||||
<a href="{{ path('chill_person_accompanying_period_update', {'person_id' : person.id, 'period_id' : accompanying_period.id } ) }}" class="sc-button bt-update no-content"></a>
|
||||
</li>
|
||||
{% if accompanying_period.isOpen == true %}
|
||||
<li>
|
||||
<a href="{{ path('chill_person_accompanying_period_close', {'person_id' : person.id}) }}" class="sc-button bt-update has-hidden change-icon">
|
||||
<i class="fa fa-lock" aria-hidden="true"></i><span class="show-on-hover">{{'Close accompanying period'|trans }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if accompanying_period.canBeReOpened == true %}
|
||||
<li>
|
||||
<a href="{{ path('chill_person_accompanying_period_re_open', {'person_id' : person.id, 'period_id' : accompanying_period.id } ) }}" class="sc-button bt-create change-icon has-hidden">
|
||||
<i class="fa fa-unlock" aria-hidden="true"></i><span class="show-on-hover">{{'Re-open accompanying period'|trans }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div class="form_control">
|
||||
<ul class="record_actions">
|
||||
<li class="cancel">
|
||||
<a href="{{ path ('chill_person_view', {'person_id' : person.id } ) }}" class="sc-button bt-cancel">
|
||||
{{ 'Person details'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{{ path ('chill_person_accompanying_period_create', {'person_id' : person.id } ) }}" class="sc-button bt-create has-hidden">
|
||||
<span class="show-on-hover">{{ 'Add an accompanying period in the past'|trans }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{% if person.isOpen == false %}
|
||||
<li>
|
||||
<a href="{{ path('chill_person_accompanying_period_open', {'person_id' : person.id} ) }}" class="sc-button bt-create change-icon has-hidden">
|
||||
<i class="fa fa-unlock" aria-hidden="true"></i>
|
||||
<span class="show-on-hover">{{'Begin a new accompanying period'|trans }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
{% endblock personcontent %}
|
@@ -0,0 +1,27 @@
|
||||
{% extends "@ChillPerson/layout.html.twig" %}
|
||||
|
||||
{% set activeRouteKey = 'chill_person_accompanying_period_list' %}
|
||||
|
||||
{% block title 'Re-Open a period'|trans %}
|
||||
|
||||
{% block personcontent %}
|
||||
|
||||
<h1>{{ 'Re-Open a period'|trans }}</h1>
|
||||
|
||||
<p class="message-confirm">{{ 'Are you sure you want to re-open this period ?'|trans }}<p>
|
||||
|
||||
<ul class="record_actions">
|
||||
<li class="cancel">
|
||||
<a href="{{ path('chill_person_accompanying_period_list', { 'person_id' : person.id } ) }}" class="sc-button bt-cancel">
|
||||
{{ 'Cancel'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="{{ path('chill_person_accompanying_period_re_open', {'confirm' : true, 'person_id' : person.id, 'period_id' : period.id } ) }}" class="sc-button bt-create">
|
||||
{{'Confirm'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
{% endblock personcontent %}
|
Reference in New Issue
Block a user