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

Merge branch 'master' of git.fsmpi.rwth-aachen.de:videoagwebsite/videoagwebsite

parents 8816ffd9 db6941d2
No related branches found
No related tags found
No related merge requests found
......@@ -411,3 +411,4 @@ def sortlog():
import feeds
import importer
import schedule
import sorter
from server import *
......@@ -102,11 +102,13 @@
{% endfor %}
{% for msg in get_announcements(min_announcement_level) if (not request.cookies['alert-info-'+msg.id|string]) or ismod() %}
<div class="alert alert-{{announcement_levels.get(msg.level, 'info')}}" role="alert">
{% if not ismod() %}
<a href="#" class="close" data-dismiss="alert" aria-label="close" onclick="Cookies.set('alert-info-{{msg.id}}', '1');">&times;</a>
{% endif %}
<ul class="list-unstyled">
<li>{{ valueeditor(('announcements',msg.id,'text'), msg.text|safe) }}</li>
{% if ismod() %}
<li class="pull-right">{{ valuedeletebtn(('announcements',msg.id,'deleted')) }}</li>
{% if ismod() %}
<li>{{ valueeditor(('announcements',msg.id,'internal'), msg.internal) }}</li>
<li class="pull-right">Sichtbar: {{ valuecheckbox(('announcements',msg.id,'visible'),msg.visible) }}</li>
<li>Level: {{ valueeditor(('announcements',msg.id,'level'), msg.level) }}</li>
......
......@@ -30,27 +30,39 @@
</p>
</div>
</div>
{% if featured|length > 0 %}
{% if (featured|length > 0) or ismod() %}
<div class="panel panel-default">
<div class="panel-heading">
<h1 class="panel-title">Featured</h1>
<h1 class="panel-title">Featured
{% if ismod() %}
<a class="btn btn-default" href="{{ url_for('create', table='featured', ref=request.url) }}">Neue Empfehlung</a>
{% endif %}
</h1>
</div>
<div class="panel-body">
<div id="myCarousel" class="carousel slide" data-ride="carousel" style="background-color: #EEE; min-height: 400px;">
<!-- Indicators -->
<div id="myCarousel" class="carousel slide" data-ride="carousel" style="background-color: #EEE; min-height: 400px;" {% if ismod() %}data-interval="false"{% endif %}>
<ol class="carousel-indicators">
{% for i in featured %}
<li data-target="#myCarousel" data-slide-to="0" {% if loop.first %} class="active" {% endif %}></li>
<li data-target="#myCarousel" data-slide-to="{{ loop.index0 }}" {% if loop.first %} class="active" {% endif %}></li>
{% endfor %}
</ol>
<div class="carousel-inner" role="listbox">
{% for i in featured %}
<div class="item {% if loop.first %}active{% endif %}">
{% if ismod() %}
<div class="center-block">
{{ valueeditor(('featured',i.id,'text'), i.text) }}
{{ valueeditor(('featured',i.id,'title'), i.title) }}
{{ valuecheckbox(('featured',i.id,'visible'),i.visible) }}
</div>
{% else %}
{{i.text|safe}}
<div class="carousel-caption"><h1>{{ i.title }}</h1></div>
{% endif %}
<div class="carousel-caption">{{ i.title }}</div>
</div>
{% endfor %}
</div>
{% if not ismod() %}
<a class="left carousel-control" href="#myCarousel" role="button" data-slide="prev">
<span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
......@@ -59,6 +71,7 @@
<span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
{% endif %}
</div>
</div>
</div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment