Compare commits
2 Commits
2751abcabc
...
f2c784f002
Author | SHA1 | Date | |
---|---|---|---|
f2c784f002 | |||
2f50476c47 |
|
@ -1,3 +1,4 @@
|
|||
def station(request):
|
||||
station = request.station
|
||||
return {"station": station, "audio_streams": station.streams}
|
||||
audio_streams = station.streams if station else None
|
||||
return {"station": station, "audio_streams": audio_streams}
|
||||
|
|
|
@ -2,6 +2,13 @@
|
|||
{% load static i18n humanize honeypot aircox %}
|
||||
|
||||
|
||||
{% block head_extra %}
|
||||
{{ form.media }}
|
||||
{% endblock %}
|
||||
|
||||
{% block init-scripts %}
|
||||
{% endblock %}
|
||||
|
||||
{% block top-nav-tools %}
|
||||
<a class="navbar-item" href="{% url 'program-detail' object.slug %}"
|
||||
target="new">
|
||||
|
|
|
@ -2,6 +2,7 @@ from django.contrib.auth.mixins import UserPassesTestMixin
|
|||
from django.forms import ModelForm, ImageField
|
||||
from django.urls import reverse
|
||||
|
||||
from ckeditor.fields import RichTextField
|
||||
from filer.models.imagemodels import Image
|
||||
|
||||
from ..models import Page, Program, StaticPage
|
||||
|
@ -35,6 +36,7 @@ class ProgramDetailView(BaseProgramMixin, PageDetailView):
|
|||
|
||||
|
||||
class ProgramForm(ModelForm):
|
||||
content = RichTextField()
|
||||
new_cover = ImageField(required=False)
|
||||
|
||||
class Meta:
|
||||
|
|
Loading…
Reference in New Issue
Block a user