summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--program/models.py2
-rw-r--r--program/templates/v2/host_detail.html14
2 files changed, 9 insertions, 7 deletions
diff --git a/program/models.py b/program/models.py
index 7951c35..b5123cb 100644
--- a/program/models.py
+++ b/program/models.py
@@ -240,7 +240,7 @@ class Host(models.Model):
return reverse('host-detail', args=[str(self.id)])
def active_shows(self):
- return self.shows.filter(programslots__until__gt=datetime.today)
+ return self.shows.filter(programslots__until__gt=datetime.today).distinct()
class Show(models.Model):
diff --git a/program/templates/v2/host_detail.html b/program/templates/v2/host_detail.html
index 0dff882..f5cac4d 100644
--- a/program/templates/v2/host_detail.html
+++ b/program/templates/v2/host_detail.html
@@ -7,18 +7,20 @@
<div id="content-main" class="host-detail">
<h1>{{ host.name }}</h1>
- <div id="shows">
- <div id="shows-title">Sendungen</div>
+ <div class="host">
+ <div id="shows">
+ <div id="shows-title">Sendungen</div>
{% for show in host.active_shows %}
- <div class="show bf-{{ show.broadcastformat.slug }}"><a href="/program/shows/{{ show.slug }}"> {{ show.name }}</a></div>
+ <div class="show bf-{{ show.broadcastformat.slug }}"><a href="/program/shows/{{ show.slug }}"> {{ show.name }}</a></div>
{% endfor %}
- </div>
+ </div>
{% if host.email %}
- <div id="email">E-Mail Adresse: <a href="{{ host.email }}">{{ host.email }}</a></div>
+ <div id="email">E-Mail Adresse: <a href="{{ host.email }}">{{ host.email }}</a></div>
{% endif %}
{% if host.website %}
- <div id="website">Website: <a href="{{ host.website }}">{{ host.website }}</a></div>
+ <div id="website">Website: <a href="{{ host.website }}">{{ host.website }}</a></div>
{% endif %}
+ </div>
</div>
</body>