mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-29 02:53:50 +00:00
ChillPersonBundle: add administrativeStatus property to Person
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
{% extends '@ChillMain/CRUD/Admin/index.html.twig' %}
|
||||
|
||||
{% block title %}
|
||||
{% include('@ChillMain/CRUD/_edit_title.html.twig') %}
|
||||
{% endblock %}
|
||||
|
||||
{% block admin_content %}
|
||||
{% embed '@ChillMain/CRUD/_edit_content.html.twig' %}
|
||||
{% block content_form_actions_save_and_show %}{% endblock %}
|
||||
{% endembed %}
|
||||
{% endblock admin_content %}
|
@@ -0,0 +1,42 @@
|
||||
{% extends '@ChillMain/CRUD/Admin/index.html.twig' %}
|
||||
|
||||
{% block admin_content %}
|
||||
{% embed '@ChillMain/CRUD/_index.html.twig' %}
|
||||
{% block table_entities_thead_tr %}
|
||||
<th>id</th>
|
||||
<th>{{ 'name'|trans }}</th>
|
||||
<th>{{ 'active'|trans }}</th>
|
||||
<th>{{ 'ordering'|trans }}</th>
|
||||
<th></th>
|
||||
{% endblock %}
|
||||
{% block table_entities_tbody %}
|
||||
{% for entity in entities %}
|
||||
<tr>
|
||||
<td>{{ entity.id }}</td>
|
||||
<td>{{ entity.name|localize_translatable_string }}</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>{{ entity.order }}</td>
|
||||
<td>
|
||||
<ul class="record_actions">
|
||||
<li>
|
||||
<a href="{{ chill_path_add_return_path('chill_crud_administrative_status_edit', { 'id': entity.id}) }}" class="btn btn-sm btn-edit btn-mini"></a>
|
||||
</li>
|
||||
</ul>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
{% endblock %}
|
||||
|
||||
{% block actions_before %}
|
||||
<li class='cancel'>
|
||||
<a href="{{ path('chill_main_admin_central') }}" class="btn btn-cancel">{{'Back to the admin'|trans}}</a>
|
||||
</li>
|
||||
{% endblock %}
|
||||
{% endembed %}
|
||||
{% endblock %}
|
@@ -0,0 +1,11 @@
|
||||
{% extends '@ChillMain/CRUD/Admin/index.html.twig' %}
|
||||
|
||||
{% block title %}
|
||||
{% include('@ChillMain/CRUD/_new_title.html.twig') %}
|
||||
{% endblock %}
|
||||
|
||||
{% block admin_content %}
|
||||
{% embed '@ChillMain/CRUD/_new_content.html.twig' %}
|
||||
{% block content_form_actions_save_and_show %}{% endblock %}
|
||||
{% endembed %}
|
||||
{% endblock admin_content %}
|
@@ -107,6 +107,9 @@
|
||||
{%- if form.spokenLanguages is defined -%}
|
||||
{{ form_row(form.spokenLanguages, {'label' : 'Spoken languages'}) }}
|
||||
{%- endif -%}
|
||||
{%- if form.administrativeStatus is defined -%}
|
||||
{{ form_row(form.administrativeStatus, {'label' : 'Administrative status'}) }}
|
||||
{%- endif -%}
|
||||
{%- if form.employmentStatus is defined -%}
|
||||
{{ form_row(form.employmentStatus, {'label' : 'Employment status'}) }}
|
||||
{%- endif -%}
|
||||
|
@@ -170,8 +170,20 @@ This view should receive those arguments:
|
||||
</dd>
|
||||
</dl>
|
||||
{%- endif -%}
|
||||
{% if chill_person.fields.administrative_status == 'visible' %}
|
||||
<dl>
|
||||
<dt>{{ 'Administrative status'|trans }} :</dt>
|
||||
<dd>
|
||||
{% if person.administrativeStatus is not empty %}
|
||||
{{ person.administrativeStatus.name|localize_translatable_string }}
|
||||
{% else %}
|
||||
<span class="chill-no-data-statement">{{ 'No data given'|trans }}</span>
|
||||
{% endif %}
|
||||
</dd>
|
||||
</dl>
|
||||
{% endif %}
|
||||
{% if chill_person.fields.employment_status == 'visible' %}
|
||||
<dl>
|
||||
{% if chill_person.fields.employment_status == 'visible' %}
|
||||
<dt>{{ 'Employment status'|trans }} :</dt>
|
||||
<dd>
|
||||
{% if person.employmentStatus is not empty %}
|
||||
@@ -180,8 +192,8 @@ This view should receive those arguments:
|
||||
<span class="chill-no-data-statement">{{ 'No data given'|trans }}</span>
|
||||
{% endif %}
|
||||
</dd>
|
||||
{% endif %}
|
||||
</dl>
|
||||
{% endif %}
|
||||
{%- if chill_person.fields.number_of_children == 'visible' -%}
|
||||
<dl>
|
||||
<dt>{{'Number of children'|trans}} :</dt>
|
||||
|
Reference in New Issue
Block a user