On rajoute les champs « études passées » et « expériences »

This commit is contained in:
Tom Hubrecht 2021-01-28 12:00:41 +01:00
parent 444b5e1995
commit 5585808ca8
6 changed files with 130 additions and 46 deletions

View file

@ -0,0 +1,23 @@
# Generated by Django 2.2.17 on 2021-01-28 10:27
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('fiches', '0009_auto_20210128_0019'),
]
operations = [
migrations.AddField(
model_name='profile',
name='experiences',
field=models.TextField(blank=True, verbose_name='expériences'),
),
migrations.AddField(
model_name='profile',
name='past_studies',
field=models.TextField(blank=True, verbose_name='études passées'),
),
]

View file

@ -26,6 +26,8 @@ class Profile(models.Model):
birth_date = models.DateField(
blank=True, null=True, verbose_name=_("date de naissance")
)
past_studies = models.TextField(blank=True, verbose_name=_("études passées"))
experiences = models.TextField(blank=True, verbose_name=_("expériences"))
thurne = models.CharField(blank=True, max_length=100, verbose_name=_("thurne"))
text_field = models.TextField(blank=True, verbose_name=_("champ libre"))
printing = models.BooleanField(

View file

@ -27,6 +27,7 @@
<span class="value">{{ profile.pronoun }}</span>
</div>
{% endif %}
{% if profile.department.exists %}
<div class="department">
<span class="label">{% trans "Département" %}{{ profile.department.count|pluralize }}</span>
@ -34,6 +35,7 @@
<span class="value">{% for dep in profile.department.all %}{{ dep }}{% if not forloop.last %}, {% endif %}{% endfor %}</span>
</div>
{% endif %}
{% if profile.birth_date %}
<div class="birthdate">
<span class="label">{% trans "Date de naissance" %}</span>
@ -41,6 +43,7 @@
<span class="value">{{ profile.birth_date }}</span>
</div>
{% endif %}
{% if profile.thurne %}
<div class="room">
<span class="label">{% trans "Thurne" %}</span>
@ -48,50 +51,70 @@
<span class="value">{{ profile.thurne }}</span>
</div>
{% endif %}
{% if profile.phone_set.exists %}
<div class="phone multi-entry">
<span class="label">{% trans "Téléphone" %}{{ profile.phone_set.count|pluralize }}</span>
<span class="separator"></span>
<ul class="value">
{% for p in profile.phone_set.all %}
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.number }}</span></li>
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.number }}</span></li>
{% endfor %}
</ul>
</div>
{% endif %}
{% if profile.social_set.exists %}
<div class="social multi-entry">
<span class="label">{{ profile.social_set.count|pluralize:_("Réseau social,Réseaux sociaux") }}</span>
<span class="separator"></span>
<ul class="value">
{% for p in profile.social_set.all %}
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.content }}</span></li>
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.content }}</span></li>
{% endfor %}
</ul>
</div>
{% endif %}
{% if profile.mail_set.exists %}
<div class="mail multi-entry">
<span class="label">{{ profile.mail_set.count|pluralize:_("Mail,Mails") }}</span>
<span class="separator"></span>
<ul class="value">
{% for p in profile.mail_set.all %}
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.mail }}</span></li>
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.mail }}</span></li>
{% endfor %}
</ul>
</div>
{% endif %}
{% if profile.address_set.exists %}
<div class="address multi-entry">
<span class="label">{{ profile.address_set.count|pluralize:_("Adresse,Adresses") }}</span>
<span class="separator"></span>
<ul class="value">
{% for p in profile.address_set.all %}
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.content|linebreaksbr }}</span></li>
<li><span class="type">{{ p.name }}</span><span class="value">{{ p.content|linebreaksbr }}</span></li>
{% endfor %}
</ul>
</div>
{% endif %}
{% if profile.past_studies %}
<div class="studies">
<span class="label">{% trans "Études passées" %}</span>
<span class="separator"></span>
<span class="value">{{ profile.past_studies }}</span>
</div>
{% endif %}
{% if profile.experiences %}
<div class="studies">
<span class="label">{% trans "Expériences passées" %}</span>
<span class="separator"></span>
<span class="value">{{ profile.experiences }}</span>
</div>
{% endif %}
</div>
{% if profile.text_field %}

View file

@ -55,6 +55,18 @@
<label for="id_promotion">{% trans "Promotion :" %}</label>
{{ form.promotion }}
</div>
<div class="form-entry">
<label for="id_past_studies">{% trans "Études passées :" %}</label>
<div id="free-text-edit-form" class="wide-form-entry">
{{ form.past_studies }}
</div>
</div>
<div class="form-entry">
<label for="id_experiences">{% trans "Expériences :" %}</label>
<div id="free-text-edit-form" class="wide-form-entry">
{{ form.experiences }}
</div>
</div>
<div class="form-entry">
<label for="id_birth_date">{% trans "Date de naissance :" %}</label>
{{ form.birth_date }}

Binary file not shown.

View file

@ -8,7 +8,7 @@ msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-01-28 00:03+0000\n"
"PO-Revision-Date: 2021-02-04 21:15+0100\n"
"PO-Revision-Date: 2021-02-04 21:28+0100\n"
"Last-Translator: Tom Hubrecht <tom.hubrecht@ens.fr>\n"
"Language-Team: \n"
"Language: en\n"
@ -63,48 +63,56 @@ msgid "date de naissance"
msgstr "birth date"
#: fiches/models.py:29
msgid "études passées"
msgstr "past studies"
#: fiches/models.py:30
msgid "expériences"
msgstr "experiences"
#: fiches/models.py:31
msgid "thurne"
msgstr "room"
#: fiches/models.py:30
#: fiches/models.py:32
msgid "champ libre"
msgstr "free space"
#: fiches/models.py:32
#: fiches/models.py:34
msgid "apparaître sur l'annuaire papier ?"
msgstr "appear on the paper directory?"
#: fiches/models.py:35
#: fiches/models.py:37
msgid "conserver la fiche annuaire ?"
msgstr "keep the directory record?"
#: fiches/models.py:47
#: fiches/models.py:49
msgid "nom du département"
msgstr "department name"
#: fiches/models.py:56 fiches/models.py:67 fiches/models.py:78
#: fiches/models.py:89
#: fiches/models.py:58 fiches/models.py:69 fiches/models.py:80
#: fiches/models.py:91
msgid "profil"
msgstr "profile"
#: fiches/models.py:58 fiches/models.py:69 fiches/models.py:80
#: fiches/models.py:91
#: fiches/models.py:60 fiches/models.py:71 fiches/models.py:82
#: fiches/models.py:93
msgid "type"
msgstr "type"
#: fiches/models.py:59
#: fiches/models.py:61
msgid "numéro"
msgstr "number"
#: fiches/models.py:70
#: fiches/models.py:72
msgid "contenu"
msgstr "content"
#: fiches/models.py:81
#: fiches/models.py:83
msgid "adresse mail"
msgstr "e-mail"
#: fiches/models.py:92
#: fiches/models.py:94
msgid "adresse"
msgstr "address"
@ -173,35 +181,43 @@ msgstr "years"
msgid "Pronom(s) utilisé(s)"
msgstr "Pronoun(s)"
#: fiches/templates/fiches/fiche.html:32
#: fiches/templates/fiches/fiche.html:33
msgid "Département"
msgstr "Department"
#: fiches/templates/fiches/fiche.html:39
#: fiches/templates/fiches/fiche.html:41
msgid "Date de naissance"
msgstr "Birth date"
#: fiches/templates/fiches/fiche.html:46
#: fiches/templates/fiches/fiche.html:49
msgid "Thurne"
msgstr "Room"
#: fiches/templates/fiches/fiche.html:53
#: fiches/templates/fiches/fiche.html:57
msgid "Téléphone"
msgstr "Phone number"
#: fiches/templates/fiches/fiche.html:64
#: fiches/templates/fiches/fiche.html:69
msgid "Réseau social,Réseaux sociaux"
msgstr "Social network,Social networks"
#: fiches/templates/fiches/fiche.html:75
#: fiches/templates/fiches/fiche.html:81
msgid "Mail,Mails"
msgstr "E-mail,E-mails"
#: fiches/templates/fiches/fiche.html:86
#: fiches/templates/fiches/fiche.html:93
msgid "Adresse,Adresses"
msgstr "Address,Addresses"
#: fiches/templates/fiches/fiche.html:99
#: fiches/templates/fiches/fiche.html:105
msgid "Études passées"
msgstr "Past studies"
#: fiches/templates/fiches/fiche.html:113
msgid "Expériences passées"
msgstr "Experiences"
#: fiches/templates/fiches/fiche.html:122
msgid "Champ libre"
msgstr "Free space"
@ -243,90 +259,98 @@ msgid "Promotion :"
msgstr "Entry year:"
#: fiches/templates/fiches/fiches_modif.html:59
msgid "Études passées :"
msgstr "Past studies:"
#: fiches/templates/fiches/fiches_modif.html:65
msgid "Expériences :"
msgstr "Experiences:"
#: fiches/templates/fiches/fiches_modif.html:71
msgid "Date de naissance :"
msgstr "Birth date:"
#: fiches/templates/fiches/fiches_modif.html:63
#: fiches/templates/fiches/fiches_modif.html:75
msgid "Thurne :"
msgstr "Room :"
#: fiches/templates/fiches/fiches_modif.html:66
#: fiches/templates/fiches/fiches_modif.html:78
msgid "Personnel"
msgstr "Private"
#: fiches/templates/fiches/fiches_modif.html:66
#: fiches/templates/fiches/fiches_modif.html:78
msgid "0612345678"
msgstr "0612345678"
#: fiches/templates/fiches/fiches_modif.html:67
#: fiches/templates/fiches/fiches_modif.html:79
msgid "Numéro(s) de téléphone :"
msgstr "Phone number(s):"
#: fiches/templates/fiches/fiches_modif.html:68
#: fiches/templates/fiches/fiches_modif.html:80
msgid "Ajouter un numéro"
msgstr "Add a phone number"
#: fiches/templates/fiches/fiches_modif.html:71
#: fiches/templates/fiches/fiches_modif.html:83
msgid "InstaTok"
msgstr "InstaTok"
#: fiches/templates/fiches/fiches_modif.html:71
#: fiches/templates/fiches/fiches_modif.html:83
msgid "mon_profil_instatok"
msgstr "my_instatok_profile"
#: fiches/templates/fiches/fiches_modif.html:72
#: fiches/templates/fiches/fiches_modif.html:84
msgid "Réseaux sociaux :"
msgstr "Social networks:"
#: fiches/templates/fiches/fiches_modif.html:73
#: fiches/templates/fiches/fiches_modif.html:85
msgid "Ajouter un réseau social"
msgstr "Add a social network"
#: fiches/templates/fiches/fiches_modif.html:76
#: fiches/templates/fiches/fiches_modif.html:88
msgid "Professionelle"
msgstr "Professional"
#: fiches/templates/fiches/fiches_modif.html:76
#: fiches/templates/fiches/fiches_modif.html:88
msgid "moi@ens.fr"
msgstr "me@ens.fr"
#: fiches/templates/fiches/fiches_modif.html:77
#: fiches/templates/fiches/fiches_modif.html:89
msgid "Mail(s) :"
msgstr "E-mail(s):"
#: fiches/templates/fiches/fiches_modif.html:78
#: fiches/templates/fiches/fiches_modif.html:90
msgid "Ajouter un email"
msgstr "Add an e-mail"
#: fiches/templates/fiches/fiches_modif.html:81
#: fiches/templates/fiches/fiches_modif.html:93
msgid "Bureau"
msgstr "Office"
#: fiches/templates/fiches/fiches_modif.html:81
#: fiches/templates/fiches/fiches_modif.html:93
msgid "45 rue d'Ulm"
msgstr "45 rue d'Ulm"
#: fiches/templates/fiches/fiches_modif.html:82
#: fiches/templates/fiches/fiches_modif.html:94
msgid "Adresse(s) :"
msgstr "Address(es):"
#: fiches/templates/fiches/fiches_modif.html:83
#: fiches/templates/fiches/fiches_modif.html:95
msgid "Ajouter une adresse"
msgstr "Add an address"
#: fiches/templates/fiches/fiches_modif.html:87
#: fiches/templates/fiches/fiches_modif.html:99
msgid "Champ libre :"
msgstr "Free space:"
#: fiches/templates/fiches/fiches_modif.html:93
#: fiches/templates/fiches/fiches_modif.html:105
msgid "Apparaître sur l'annuaire papier ?"
msgstr "Appear on the paper directory?"
#: fiches/templates/fiches/fiches_modif.html:97
#: fiches/templates/fiches/fiches_modif.html:109
msgid "Conserver la fiche annuaire ?"
msgstr "Keep the directory record?"
#: fiches/templates/fiches/fiches_modif.html:100
#: fiches/templates/fiches/fiches_modif.html:112
msgid "Enregistrer"
msgstr "Save"