Meilleur affichage des dates
Configure la localisation (i10n) de Django afin d’afficher un format plus user-friendly par défaut pour les dates (par exemple, afficher "21 septembre 2016 à 15:00" plutôt que "21 septembre 2016 15:00"). Ceci permet d’éliminer les utilisations de `date_no_seconds` pour simplement les remplacer par l’affichage de la date, le format par défaut étant maintenant satisfaisant. Attention : le bon fonctionnement de ceci nécessite de changer les settings afin d’utiliser le module `cof.locale` comme module de localisation (définir `FORMAT_MODULE_PATH = "cof.locale"`). Le module `cof.locale` définit le format d’affichage des dates+heures (`DATETIME_FORMAT`) afin d’incorporer le "à" qui n'est pas présent dans la localisation française de Django.
This commit is contained in:
parent
afed3479b0
commit
567c9a0a6d
14 changed files with 24 additions and 23 deletions
|
@ -22,7 +22,7 @@
|
|||
|
||||
{% for show, members, losers in results %}
|
||||
<div class="attribresult">
|
||||
<h3 class="horizontal-title">{{ show.title }} - {{ show.date_no_seconds }} @ {{ show.location }}</h3>
|
||||
<h3 class="horizontal-title">{{ show.title }} - {{ show.date }} @ {{ show.location }}</h3>
|
||||
<p>
|
||||
<strong>{{ show.nrequests }} demandes pour {{ show.slots }} places</strong>
|
||||
{{ show.price }}€ par place{% if user.profile.is_buro and show.nrequests < show.slots %}, {{ show.deficit }}€ de déficit{% endif %}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
Bonjour {{ vendeur.first_name }} !
|
||||
|
||||
Je souhaiterais racheter ta place pour {{ spectacle.title }} le {{ spectacle.date_no_seconds }} ({{ spectacle.location }}) à {{ spectacle.price|floatformat:2 }}€.
|
||||
Je souhaiterais racheter ta place pour {{ spectacle.title }} le {{ spectacle.date }} ({{ spectacle.location }}) à {{ spectacle.price|floatformat:2 }}€.
|
||||
Contacte-moi si tu es toujours intéressé·e !
|
||||
|
||||
{{ acheteur.get_full_name }} ({{ acheteur.email }})
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
Bonjour {{ name }},
|
||||
|
||||
Nous te rappellons que tu as eu la chance d'obtenir {{ nb_attr|pluralize:"une place,deux places" }}
|
||||
pour {{ show.title }}, le {{ show.date_no_seconds }} au {{ show.location }}. N'oublie pas de t'y rendre !
|
||||
pour {{ show.title }}, le {{ show.date }} au {{ show.location }}. N'oublie pas de t'y rendre !
|
||||
{% if nb_attr == 2 %}
|
||||
Tu as obtenu deux places pour ce spectacle. Nous te rappelons que
|
||||
ces places sont strictement réservées aux personnes de moins de 28 ans.
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
Bonjour {{ acheteur.first_name }},
|
||||
|
||||
Tu as été tiré-e au sort pour racheter une place pour {{ spectacle.title }} le {{ spectacle.date_no_seconds }} ({{ spectacle.location }}) à {{ spectacle.price|floatformat:2 }}€.
|
||||
Tu as été tiré-e au sort pour racheter une place pour {{ spectacle.title }} le {{ spectacle.date }} ({{ spectacle.location }}) à {{ spectacle.price|floatformat:2 }}€.
|
||||
Tu peux contacter le/la vendeur-se à l'adresse {{ vendeur.email }}, ou en répondant à ce mail.
|
||||
|
||||
Chaleureusement,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
Bonjour {{ user.first_name }}
|
||||
|
||||
Une place pour le spectacle {{ spectacle.title }} ({{ spectacle.date_no_seconds }})
|
||||
Une place pour le spectacle {{ spectacle.title }} ({{ spectacle.date }})
|
||||
a été postée sur BdA-Revente.
|
||||
|
||||
Si ce spectacle t'intéresse toujours, merci de nous le signaler en cliquant
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
Bonjour {{ user.first_name }}
|
||||
|
||||
Une place pour le spectacle {{ spectacle.title }} ({{ spectacle.date_no_seconds }})
|
||||
Une place pour le spectacle {{ spectacle.title }} ({{ spectacle.date }})
|
||||
a été postée sur BdA-Revente.
|
||||
|
||||
Puisque ce spectacle a lieu dans moins de 24h, il n'y a pas de tirage au sort pour
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
{% for spectacle in spectacles %}
|
||||
<tr>
|
||||
<td>{{ spectacle.title }}</td>
|
||||
<td data-sort-value="{{ spectacle.timestamp }}">{{ spectacle.date_no_seconds }}</td>
|
||||
<td data-sort-value="{{ spectacle.timestamp }}">{{ spectacle.date }}</td>
|
||||
<td data-sort-value="{{ spectacle.location }}">{{ spectacle.location }}</td>
|
||||
<td data-sort-value="{{ spectacle.slots }}">{{ spectacle.slots }} places</td>
|
||||
<td data-sort-value="{{ spectacle.total }}">{{ spectacle.total }} demandes</td>
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<tr>
|
||||
<td>{{place.spectacle.title}}</td>
|
||||
<td>{{place.spectacle.location}}</td>
|
||||
<td>{{place.spectacle.date_no_seconds}}</td>
|
||||
<td>{{place.spectacle.date}}</td>
|
||||
<td>{% if place.double %}deux places{%else%}une place{% endif %}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
{% for spectacle in object_list %}
|
||||
<tr class="clickable-row" data-href="{% url 'bda-spectacle' tirage_id spectacle.id %}">
|
||||
<td><a href="{% url 'bda-spectacle' tirage_id spectacle.id %}">{{ spectacle.title }} <span style="font-size:small;" class="glyphicon glyphicon-link" aria-hidden="true"></span></a></td>
|
||||
<td data-sort-value="{{ spectacle.timestamp }}">{{ spectacle.date_no_seconds }}</td>
|
||||
<td data-sort-value="{{ spectacle.timestamp }}">{{ spectacle.date }}</td>
|
||||
<td data-sort-value="{{ spectacle.location }}">{{ spectacle.location }}</td>
|
||||
<td data-sort-value="{{ spectacle.price |stringformat:".3f" }}">
|
||||
{{ spectacle.price |floatformat }}€
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue