Skip to content
Snippets Groups Projects
Commit 96a63fae authored by Julian Rother's avatar Julian Rother
Browse files

Renamed live property to livehandle

parent 17f610ad
No related branches found
No related tags found
No related merge requests found
......@@ -344,7 +344,7 @@ def index():
GROUP BY videos.lecture_id
ORDER BY MAX(videos.time_created) DESC
LIMIT 6 ''',ismod())
livestreams = query('''SELECT streams.handle AS live, lectures.*, "course" AS sep, courses.*
livestreams = query('''SELECT streams.handle AS livehandle, lectures.*, "course" AS sep, courses.*
FROM streams
JOIN lectures ON lectures.id = streams.lecture_id
JOIN courses ON courses.id = lectures.course_id
......@@ -375,7 +375,7 @@ def genlive(streams):
for stream in streams:
stream['visible'] = True
stream['downloadable'] = False
stream['path'] = 'pub/hls/%s.m3u8'%stream['live']
stream['path'] = 'pub/hls/%s.m3u8'%stream['livehandle']
stream['file_size'] = 0
return streams
......@@ -406,7 +406,7 @@ def course(id=None, handle=None):
WHERE lectures.course_id= ? AND (? OR videos.visible)
ORDER BY lectures.time, formats.prio DESC
''', course['id'], ismod())
livestreams = query('''SELECT streams.handle AS live, streams.lecture_id, formats.description AS format_description, formats.player_prio, formats.prio
livestreams = query('''SELECT streams.handle AS livehandle, streams.lecture_id, formats.description AS format_description, formats.player_prio, formats.prio
FROM streams
JOIN lectures ON lectures.id = streams.lecture_id
JOIN formats ON formats.keywords = "hls"
......@@ -435,7 +435,7 @@ def lecture(id, course=None, courseid=None):
WHERE videos.lecture_id = ? AND (? OR videos.visible)
ORDER BY formats.prio DESC
''', lecture['course_id'], lecture['id'], ismod())
livestreams = query('''SELECT streams.handle AS live, streams.lecture_id, formats.description AS format_description, formats.player_prio, formats.prio, formats.mimetype
livestreams = query('''SELECT streams.handle AS livehandle, streams.lecture_id, formats.description AS format_description, formats.player_prio, formats.prio, formats.mimetype
FROM streams
JOIN lectures ON lectures.id = streams.lecture_id
JOIN formats ON formats.keywords = "hls"
......
......@@ -5,7 +5,7 @@
<div class="row">
<img class="col-xs-4" style="max-height: 120px; height: auto; width:170px" src="{{ config.VIDEOPREFIX }}/thumbnail/l_{{ lecture['id'] }}.jpg" alt="Vorschaubild">
<div class="col-xs-4">
<span>{% if lecture.live %}<span class="label label-danger">Live</span> {% endif %}<strong>{{ lecture.course.short }}</strong>{% if ismod() %} <i>({{lecture.course_id}})</i>{% endif %}</span><br>
<span>{% if lecture.livehandle %}<span class="label label-danger">Live</span> {% endif %}<strong>{{ lecture.course.short }}</strong>{% if ismod() %} <i>({{lecture.course_id}})</i>{% endif %}</span><br>
<span>{% if ismod() %}ID: {{lecture.id}}{% endif %}</span><br>
<span>{{ lecture['time'] }}</span>
{% if lecture['speaker'] %}
......@@ -23,7 +23,7 @@
<img style="width: 100%;" src="{{ config.VIDEOPREFIX }}/thumbnail/l_{{ lecture['id'] }}.jpg" alt="Vorschaubild">
</li>
<li>
{% if lecture.live %}<span class="label label-danger">Live</span> {% endif %}
{% if lecture.livehandle %}<span class="label label-danger">Live</span> {% endif %}
<strong>{{ lecture.course.title }}</strong>
</li>
<li>{{ lecture['time'] }}</li>
......@@ -169,7 +169,7 @@ $('#embedcodebtn').popover(
{% endif %}
</div>
<ul class="list-unstyled col-sm-3 col-xs-12">
<li>{% if videos|selectattr("live")|list|length %}<span class="label label-danger">Live</span> {% endif %}{{ moderator_editor(['lectures',lecture.id,'title'], lecture.title) }}</li>
<li>{% if videos|selectattr("livehandle")|list|length %}<span class="label label-danger">Live</span> {% endif %}{{ moderator_editor(['lectures',lecture.id,'title'], lecture.title) }}</li>
{% if lecture.speaker or ismod() %}<li>Gehalten von {{ moderator_editor(['lectures',lecture.id,'speaker'], lecture.speaker) }}</li>{% endif %}
<li>{{ moderator_editor(['lectures',lecture.id,'time'], lecture.time) }} </li>
<li>Dauer: {{ moderator_editor(['lectures',lecture.id,'duration'], lecture.duration) }} min</li>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment