Improve templating in Closing Motive admin

This commit is contained in:
Julien Fastré 2020-07-06 13:25:24 +02:00
parent da9d1120ac
commit 30eacea228
3 changed files with 12 additions and 1 deletions

View File

@ -113,3 +113,5 @@ Master branch
- [Accompanying period list] Fix label of closing motive
- [Person details] Add an "empty" statement on place of birth
- [Person list] Add a lock/unlock icon instead of open/closed folder in result list;
- [Admin closing motive] Remove links to Closing motive View;
- [Admin closing motive] Improve icons for active in list of closing motive;

View File

@ -7,5 +7,6 @@
{% block admin_content %}
{% embed '@ChillMain/CRUD/_edit_content.html.twig' %}
{% block content_form_actions_view %}{% endblock %}
{% block content_form_actions_save_and_show %}{% endblock %}
{% endembed %}
{% endblock %}

View File

@ -14,15 +14,23 @@
<tr>
<td>{{ entity.ordering }}</td>
<td>{{ entity|chill_entity_render_box }}</td>
<td>{{ entity.active }}</td>
<td style="text-align:center">
{% if entity.active %}
<i class="fa fa-check-square-o"></i>
{% else %}
<i class="fa fa-square-o"></i>
{% endif %}
</td>
<td>
<ul class="record_actions">
<li>
<a href="{{ chill_path_add_return_path('chill_crud_closing_motive_edit', { 'id': entity.id }) }}" class="sc-button bt-edit"></a>
</li>
{% if entity.active %}
<li>
<a href="{{ chill_path_add_return_path('chill_crud_closing_motive_new', { 'parent_id': entity.id } ) }}" class="sc-button bt-new">{{ 'closing_motive.new child'|trans }}</a>
</li>
{% endif %}
</ul>
</td>
</tr>