mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-11-22 03:47:48 +00:00
Resolve "Fusion actions d'accompagnement"
This commit is contained in:
@@ -68,6 +68,14 @@
|
||||
{% endif %}
|
||||
</div>
|
||||
</li>
|
||||
{% if work.accompanyingPeriod.getWorks|length > 1 %}
|
||||
<li>
|
||||
<a class="btn btn-misc" href="{{ chill_path_add_return_path('chill_person_accompanying_period_work_assign_duplicate', { 'id': work.id }) }}">
|
||||
<i class="bi bi-chevron-contract"></i>
|
||||
{{ 'Merge'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if is_granted('CHILL_MAIN_ACCOMPANYING_PERIOD_WORK_UPDATE', work) %}
|
||||
<li>
|
||||
<a class="btn btn-edit"
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
{%- macro details(w, accompanyingCourse, options) -%}
|
||||
{% include '@ChillPerson/AccompanyingCourseWork/_item.html.twig' with {
|
||||
'displayAction': false,
|
||||
'displayContent': 'short',
|
||||
'displayFontSmall': true,
|
||||
'itemBlocClass': '',
|
||||
'displayNotification': false
|
||||
} %}
|
||||
{% endmacro %}
|
||||
@@ -0,0 +1,53 @@
|
||||
{% extends '@ChillPerson/AccompanyingCourse/layout.html.twig' %}
|
||||
|
||||
{% set activeRouteKey = 'chill_person_accompanying_period_work_assign_duplicate' %}
|
||||
|
||||
{% block title %}{{ 'Assign an accompanying period work duplicate' }}{% endblock %}
|
||||
|
||||
{% import '@ChillPerson/AccompanyingPeriodWorkDuplicate/_details.html.twig' as details %}
|
||||
|
||||
{% block content %}
|
||||
<div class="person-duplicate">
|
||||
|
||||
<div class="col">
|
||||
<h4>{{ 'acpw_duplicate.to keep'|trans ~ ':' }}</h4>
|
||||
<div class="accompanying-course-work">
|
||||
<div class="flex-table">
|
||||
{{ details.details(acpw, accompanyingCourse) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h3>{{ 'acpw_duplicate.Assign duplicate'|trans }}</h3>
|
||||
{{ form_start(form) }}
|
||||
{%- if form.acpw is defined -%}
|
||||
{{ form_row(form.acpw) }}
|
||||
<div id="linked-acpw-selector" data-accompanying-period='{{ accompanyingCourse.id }}'></div>
|
||||
{% endif %}
|
||||
{{ form_rest(form) }}
|
||||
|
||||
<ul class="record_actions sticky-form-buttons">
|
||||
<li class="cancel">
|
||||
<a href="{{ path('chill_person_accompanying_period_work_show', {'id' : acpw.id}) }}" class="btn btn-cancel">
|
||||
{{ 'Return'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<button class="btn btn-action" type="submit">{{ 'Next'|trans }}</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
{{ form_end(form) }}
|
||||
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block js %}
|
||||
{{ parent() }}
|
||||
{{ encore_entry_script_tags('mod_duplicate_selector') }}
|
||||
{% endblock %}
|
||||
|
||||
{% block css %}
|
||||
{{ parent() }}
|
||||
{{ encore_entry_link_tags('mod_duplicate_selector') }}
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,72 @@
|
||||
{% extends "@ChillPerson/AccompanyingCourse/layout.html.twig" %}
|
||||
|
||||
{% import '@ChillPerson/AccompanyingPeriodWorkDuplicate/_details.html.twig' as details %}
|
||||
|
||||
{% block title %}{{ 'acpw_duplicate.title'|trans }}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container-fluid content"><div class="duplicate-content">
|
||||
|
||||
<h1>{{ 'acpw_duplicate.title'|trans }}</h1>
|
||||
<div class="col-md-11 border mb-3 mt-3 p-2">
|
||||
<p>{{ 'acpw_duplicate.description'|trans }}</p>
|
||||
</div>
|
||||
|
||||
<div class="col-md-11">
|
||||
<div class="col">
|
||||
<h4>{{ 'acpw_duplicate.to delete'|trans ~ ':' }}</h4>
|
||||
<div class="accompanying-course-work">
|
||||
<div class="flex-table">
|
||||
{{ details.details(acpw2, accompanyingCourse) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-11 mt-3">
|
||||
<div class="col">
|
||||
<h4>{{ 'acpw_duplicate.to keep'|trans ~ ':' }}</h4>
|
||||
<div class="accompanying-course-work">
|
||||
<div class="flex-table">
|
||||
{{ details.details(acpw, accompanyingCourse) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{ form_start(form) }}
|
||||
|
||||
<div class="col-md-12 centered">
|
||||
|
||||
<div class="container-fluid" style="padding-top: 1em;">
|
||||
<div class="clear" style="padding-top: 10px;">
|
||||
{{ form_widget(form.confirm) }}
|
||||
</div>
|
||||
<div class="col-11">
|
||||
{{ form_label(form.confirm) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<ul class="col-12 record_actions">
|
||||
<li class="cancel">
|
||||
<a href="{{ path('chill_person_accompanying_period_work_assign_duplicate', {id : acpw.id}) }}" class="btn btn-cancel">
|
||||
{{ 'Return'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
<li class="cancel">
|
||||
<a href="{{ path('chill_person_acpw_duplicate_confirm', { acpw1_id : acpw2.id, acpw2_id : acpw.id }) }}"
|
||||
class="btn btn-action">
|
||||
<i class="fa fa-exchange"></i>
|
||||
{{ 'Invert'|trans }}
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<button class="btn btn-submit" type="submit"><i class="bi bi-chevron-contract"></i>{{ 'Merge'|trans }}</button>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
{{ form_end(form) }}
|
||||
|
||||
</div></div>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user