hotfix: inheritance in calendar
This commit is contained in:
parent
bd84b46476
commit
504044b1cf
1 changed files with 9 additions and 5 deletions
|
@ -35,24 +35,28 @@
|
|||
{% for activity in day.list %}
|
||||
<div class="cal-event">
|
||||
<span class="cal-event-id">{{ activity.id }}</span>
|
||||
<span class="cal-event-name">{{ activity.title }}</span>
|
||||
<span class="cal-event-name">{{ activity|get_herited:'title' }}</span>
|
||||
<span class="cal-event-start-date">{{ activity.beginning | date:"j/m/Y H:i" }}</span>
|
||||
<span class="cal-event-end-date">{{ activity.end | date:"j/m/Y H:i" }}</span>
|
||||
<span class="cal-event-location">{{ activity.places.all | join:", " }}</span>
|
||||
{% with activity|get_herited:'places' as places %}
|
||||
<span class="cal-event-location">{{ places.all | join:", " }}</span>
|
||||
{% endwith %}
|
||||
<span class="cal-event-description">{{ activity.description }}</span>
|
||||
<span class="cal-event-url">{% url "event:activity" activity.id %}</span>
|
||||
|
||||
{% if activity.has_perm %}
|
||||
<span class="cal-event-has-perms">1</span>
|
||||
<span class="cal-event-min-nb-perms">{{ activity.min_perm }}</span>
|
||||
<span class="cal-event-max-nb-perms">{{ activity.max_perm }}</span>
|
||||
<span class="cal-event-min-nb-perms">{{ activity|get_herited:'min_perm' }}</span>
|
||||
<span class="cal-event-max-nb-perms">{{ activity|get_herited:'max_perm' }}</span>
|
||||
<span class="cal-event-nb-perms">{{ activity.staff.count }}</span>
|
||||
<span class="cal-event-subscribed">{% is_enrolled activity request.user %}</span>
|
||||
{% endif %}
|
||||
|
||||
{% for tag in activity.tags.all %}
|
||||
{% with activity|get_herited:'tags' as tags %}
|
||||
{% for tag in tags.all %}
|
||||
<span class="cal-event-tag">{{ tag.name }}</span>
|
||||
{% endfor %}
|
||||
{% endwith %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
|
|
Loading…
Reference in a new issue