Added Slot.content_override

Slots can now be controlled through content_override if custom content is
needed in non-talk slots.
This commit is contained in:
Brian Rosner 2012-10-24 23:21:20 -06:00
parent 06ea84331c
commit d7ac510555
3 changed files with 11 additions and 2 deletions

View file

@ -48,6 +48,7 @@ class Slot(models.Model):
kind = models.ForeignKey(SlotKind)
start = models.TimeField()
end = models.TimeField()
content_override = models.TextField(blank=True)
def assign(self, content):
"""

View file

@ -18,7 +18,11 @@
<div class="speaker">{{ slot.content.speaker }}</div>
{% endif %}
{% else %}
{{ slot.kind.label }}
{% if slot.content_override %}
{{ slot.content_override|safe }}
{% else %}
{{ slot.kind.label }}
{% endif %}
{% endif %}
</td>
{% endfor %}

View file

@ -17,7 +17,11 @@
<div class="speaker">{{ slot.content.speaker }}</div>
{% endif %}
{% else %}
{{ slot.kind.label }}
{% if slot.content_override %}
{{ slot.content_override|safe }}
{% else %}
{{ slot.kind.label }}
{% endif %}
{% endif %}
</td>
{% endfor %}