Même pour un événement à plusieurs jours, on indique l'heure de début si elle est disponible pour son premier jour
This commit is contained in:
parent
8bdc9a1948
commit
b21cc8ee8c
@ -120,8 +120,6 @@ class Event(models.Model):
|
||||
|
||||
tags = ArrayField(models.CharField(max_length=64), verbose_name=_('Tags'), help_text=_("A list of tags that describe the event."), blank=True, null=True)
|
||||
|
||||
def single_day(self):
|
||||
return not self.end_day or self.end_day == self.start_day
|
||||
|
||||
def get_absolute_url(self):
|
||||
return reverse("view_event", kwargs={"pk": self.pk, "extra": slugify(self.title)})
|
||||
|
@ -30,7 +30,7 @@
|
||||
<ul>
|
||||
{% for event in events %}
|
||||
<li>
|
||||
{% if event.single_day and event.start_time %}
|
||||
{% if event.start_day == day.date and event.start_time %}
|
||||
{{ event.start_time }}
|
||||
{% endif %}
|
||||
<a href="{{ event.get_absolute_url }}">{{ event|picto_status }} {{ event.title }}</a>
|
||||
@ -52,7 +52,7 @@
|
||||
<ul>
|
||||
{% for event in day.events %}
|
||||
<li>{{ event.category | circle_cat }}
|
||||
{% if event.single_day and event.start_time %}
|
||||
{% if event.start_day == day.date and event.start_time %}
|
||||
{{ event.start_time }}
|
||||
{% endif %}
|
||||
{{ event|picto_status }} <a href="{{ daytag }}" data-target="event-{{ event.id }}" onClick="toggleModal(event)">{{ event.title }}</a>
|
||||
|
Loading…
Reference in New Issue
Block a user