mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-29 18:14:59 +00:00
Add external identifiers for person, editable in edit form, with minimal features associated
This commit is contained in:
@@ -281,11 +281,6 @@ abbr.referrer { // still used ?
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.created-updated {
|
||||
border: 1px solid black;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
/// Masonry blocs on AccompanyingCourse resume page
|
||||
div#dashboards {
|
||||
div.mbloc {
|
||||
|
@@ -8,7 +8,7 @@
|
||||
<h1>
|
||||
<i class="fa fa-random fa-fw"></i>
|
||||
{{ 'Accompanying Course'|trans }}
|
||||
<span class="id-number">{{ accompanyingCourse.id }}</span>
|
||||
<span class="id-number">({{ 'accompanying_period.number'|trans({ 'id': accompanyingCourse.id}) }})</span>
|
||||
</h1>
|
||||
</div>
|
||||
</div>
|
||||
|
@@ -78,11 +78,6 @@
|
||||
{%- if options['addEntity'] -%}
|
||||
<span class="badge rounded-pill bg-secondary">{{ 'Person'|trans }}</span>
|
||||
{%- endif -%}
|
||||
{%- if options['addId'] -%}
|
||||
<span class="id-number" title="{{ 'Person'|trans ~ ' n° ' ~ person.id }}">
|
||||
{{ person.id|upper -}}
|
||||
</span>
|
||||
{%- endif -%}
|
||||
</div>
|
||||
{%- if options['addInfo'] -%}
|
||||
<p class="moreinfo">
|
||||
@@ -99,6 +94,12 @@
|
||||
{%- if options['addAge'] -%}
|
||||
<span class="age"> {{ 'years_old'|trans({ 'age': person.age }) }}</span>
|
||||
{%- endif -%}
|
||||
{%- if options['addId'] -%}
|
||||
{%- set personId = person|chill_person_id_render_text %}
|
||||
<span class="id-number" title="{{ 'Person'|trans ~ ' ' ~ personId }}">
|
||||
({{ personId }})
|
||||
</span>
|
||||
{%- endif -%}
|
||||
{%- elseif person.birthdate is not null -%}
|
||||
<time datetime="{{ person.birthdate|date('Y-m-d') }}" title="{{ 'Birthdate'|trans }}">
|
||||
{{ 'Born the date'|trans({'gender': person.gender ? person.gender.genderTranslation.value : 'neutral',
|
||||
@@ -108,6 +109,12 @@
|
||||
<span class="age">{{- 'years_old'|trans({ 'age': person.age }) -}}</span>
|
||||
{%- endif -%}
|
||||
{%- endif -%}
|
||||
{%- if options['addId'] -%}
|
||||
{%- set personId = person|chill_person_id_render_text %}
|
||||
<span class="id-number same-size" title="{{ 'Person'|trans ~ ' ' ~ personId }}">
|
||||
({{ personId }})
|
||||
</span>
|
||||
{%- endif -%}
|
||||
</p>
|
||||
{%- endif -%}
|
||||
{#- tricks to remove easily whitespace after template -#}
|
||||
|
@@ -31,7 +31,7 @@
|
||||
{% if form.memo is defined %}
|
||||
<fieldset>
|
||||
<legend><h2>{{ 'Memo'|trans }}</h2></legend>
|
||||
{{ form_row(form.memo, {'label' : 'Memo'} ) }}
|
||||
{{ form_widget(form.memo, {'label' : 'Memo'} ) }}
|
||||
</fieldset>
|
||||
{% endif %}
|
||||
|
||||
@@ -85,15 +85,17 @@
|
||||
{{ form_row(form.mobilenumber, {'label': 'Mobilenumber'}) }}
|
||||
</div>
|
||||
<div id="personAcceptSMS">
|
||||
{{ form_row(form.acceptSMS, {'label' : 'Accept short text message ?'}) }}
|
||||
{{ form_row(form.acceptSms, {'label' : 'Accept short text message ?'}) }}
|
||||
</div>
|
||||
{%- endif -%}
|
||||
{%- if form.otherPhoneNumbers is defined -%}
|
||||
{{ form_widget(form.otherPhoneNumbers) }}
|
||||
{{ form_errors(form.otherPhoneNumbers) }}
|
||||
{%- if form.otherPhonenumbers is defined -%}
|
||||
{{ form_widget(form.otherPhonenumbers) }}
|
||||
{{ form_errors(form.otherPhonenumbers) }}
|
||||
{%- endif -%}
|
||||
{%- if form.contactInfo is defined -%}
|
||||
{{ form_row(form.contactInfo, {'label': 'Notes on contact information'}) }}
|
||||
{{ form_label(form.contactInfo) }}
|
||||
{{ form_widget(form.contactInfo) }}
|
||||
{{ form_errors(form.contactInfo) }}
|
||||
{%- endif -%}
|
||||
</fieldset>
|
||||
{%- endif -%}
|
||||
@@ -134,6 +136,20 @@
|
||||
</fieldset>
|
||||
{%- endif -%}
|
||||
|
||||
{% if form.identifiers|length > 0 %}
|
||||
<fieldset>
|
||||
<legend><h2>{{ 'person.Identifiers'|trans }}</h2></legend>
|
||||
<div>
|
||||
{% for f in form.identifiers %}
|
||||
{{ form_row(f) }}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</fieldset>
|
||||
{% else %}
|
||||
{{ form_widget(form.identifiers) }}
|
||||
{% endif %}
|
||||
|
||||
|
||||
{{ form_rest(form) }}
|
||||
|
||||
<ul class="record_actions sticky-form-buttons">
|
||||
|
@@ -1,19 +1,3 @@
|
||||
{#
|
||||
* Copyright (C) 2014, Champs Libres Cooperative SCRLFS, <http://www.champs-libres.coop>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Affero General Public License as
|
||||
* published by the Free Software Foundation, either version 3 of the
|
||||
* License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU Affero General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Affero General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#}
|
||||
{% extends "@ChillPerson/Person/layout.html.twig" %}
|
||||
|
||||
{% set activeRouteKey = 'chill_person_view' %}
|
||||
@@ -78,6 +62,16 @@ This view should receive those arguments:
|
||||
{% else %}
|
||||
<dd>{{ 'gender.not defined'|trans }}</dd>
|
||||
{% endif %}
|
||||
|
||||
{% if person.genderComment.comment is not empty %}
|
||||
<dt>{{ 'Gender comment'|trans }} :</dt>
|
||||
<dd>
|
||||
<div class="chill-user-quote">
|
||||
{{ person.genderComment.comment|chill_markdown_to_html }}
|
||||
</div>
|
||||
</dd>
|
||||
{% endif %}
|
||||
|
||||
</dl>
|
||||
</figure>
|
||||
</div>
|
||||
@@ -126,16 +120,6 @@ This view should receive those arguments:
|
||||
</figure>
|
||||
</div>
|
||||
|
||||
{% if person.genderComment.comment is not empty %}
|
||||
<div class="col-12">
|
||||
<figure class="person-details">
|
||||
<h2 class="chill-beige">{{ 'Gender comment'|trans }} :</h2>
|
||||
<div class="chill-user-quote">
|
||||
{{ person.genderComment.comment|chill_markdown_to_html }}
|
||||
</div>
|
||||
</figure>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
@@ -241,17 +225,20 @@ This view should receive those arguments:
|
||||
<span class="chill-no-data-statement">{{ 'No data given'|trans }}</span>
|
||||
{% endif %}
|
||||
</dd>
|
||||
<dt>{{ 'Comment on the marital status'|trans }} :</dt>
|
||||
|
||||
<dd>
|
||||
{% if person.maritalStatusComment.comment is not empty %}
|
||||
<blockquote class="chill-user-quote">
|
||||
{{ person.maritalStatusComment.comment|chill_markdown_to_html }}
|
||||
</blockquote>
|
||||
{% else %}
|
||||
<span class="chill-no-data-statement">{{ 'No data given'|trans }}</span>
|
||||
{% if person.maritalStatusComment.comment is not empty %}
|
||||
<dt>{{ 'Comment on the marital status'|trans }} :</dt>
|
||||
<dd>
|
||||
<blockquote class="chill-user-quote">
|
||||
{{ person.maritalStatusComment.comment|chill_markdown_to_html }}
|
||||
</blockquote>
|
||||
</dd>
|
||||
{% endif %}
|
||||
{% for identifier in person.identifiers %}
|
||||
{% if identifier.definition.isActive and (identifier|chill_entity_render_string) is not empty %}
|
||||
<dt>{{ identifier.definition.label|localize_translatable_string }} :</dt>
|
||||
<dd>{{ identifier|chill_entity_render_box }}</dd>
|
||||
{% endif %}
|
||||
</dd>
|
||||
{% endfor %}
|
||||
</dl>
|
||||
{%- endif -%}
|
||||
</figure>
|
||||
@@ -341,7 +328,7 @@ This view should receive those arguments:
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="created-updated">
|
||||
<div>
|
||||
{% if person.createdBy %}
|
||||
<div class="createdBy">
|
||||
{{ 'Created by'|trans}}: <b>{{ person.createdBy|chill_entity_render_box({'at_date': person.createdAt}) }}</b>,<br>
|
||||
|
Reference in New Issue
Block a user