Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
radiopanik
panikweb
Commits
a799e871
Commit
a799e871
authored
Aug 24, 2013
by
fred
Browse files
fill nonstop info in json onair view
parent
ea6ab855
Changes
2
Hide whitespace changes
Inline
Side-by-side
panikweb/views.py
View file @
a799e871
...
...
@@ -233,6 +233,14 @@ def onair(request):
'title'
:
d
[
'emission'
].
title
,
'url'
:
d
[
'emission'
].
get_absolute_url
()
}
if
d
.
get
(
'nonstop'
):
d
[
'nonstop'
]
=
{
'title'
:
d
[
'nonstop'
].
title
,
}
if
d
.
get
(
'current_slot'
):
d
[
'current_slot'
]
=
{
'title'
:
d
[
'current_slot'
].
title
}
return
d
...
...
panikweb_templates/templates/includes/player.html
View file @
a799e871
...
...
@@ -43,6 +43,9 @@
result
=
result
+
(
$
.
type
(
onair
.
data
.
emission
)
==
'
object
'
?
'
<strong>
'
+
onair
.
data
.
emission
.
title
+
'
</strong>
'
:
''
);
result
=
result
+
(
$
.
type
(
onair
.
data
.
episode
)
==
'
object
'
?
'
<span>
'
+
onair
.
data
.
episode
.
title
+
'
</span>
'
:
''
);
WhatsOnAir
.
html
(
result
);
}
else
if
(
onair
.
data
.
nonstop
)
{
result
=
onair
.
data
.
nonstop
.
title
;
WhatsOnAir
.
html
(
'
<strong>
'
+
result
+
'
</strong>
'
);
}
else
{
WhatsOnAir
.
html
(
'
<strong>Unknown (Probably Non-Stop)</strong>
'
);}
WhatsOnAir
.
fadeIn
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment