summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2012-02-15 19:11:07 (GMT)
committerChristian Pointner <equinox@spreadspace.org>2012-02-15 19:11:07 (GMT)
commit02f2cd4025ae1368a56016cb1756e1275645ad41 (patch)
treefeb3b58cf3ac6c91fc070aa1c5373692a68a7f31
parent6c7e6bc10c98d7619e2cae5c0694e73e14730573 (diff)
added image_enabled flag to show
-rw-r--r--program/models.py1
-rw-r--r--templates/program/show_detail.html2
2 files changed, 2 insertions, 1 deletions
diff --git a/program/models.py b/program/models.py
index 2818c5a..0b78347 100644
--- a/program/models.py
+++ b/program/models.py
@@ -88,6 +88,7 @@ class Show(models.Model):
name = models.CharField(_("Name"), max_length=255)
slug = models.CharField(_("Slug"), max_length=255, unique=True)
image = models.ImageField(_("Image"), blank=True, null=True, upload_to='show_images')
+ image_enabled = models.BooleanField(_("show Image"), default=True )
short_description = models.CharField(_("Short description"), max_length=64)
description = tinymce_models.HTMLField(_("Description"))
email = models.EmailField(_("E-Mail"), blank=True, null=True)
diff --git a/templates/program/show_detail.html b/templates/program/show_detail.html
index 661a2b5..b5c5f91 100644
--- a/templates/program/show_detail.html
+++ b/templates/program/show_detail.html
@@ -39,7 +39,7 @@
<div id="description">{{ show.description|safe }}</div>
- {% if show.image %}
+ {% if show.image and show.image_enabled %}
<div id="image" style="float: right;"><img src="/program/static/{{ show.image }}" width="200" alt="image"></div>
{% endif %}