PushingScores/templates/all.html

74 lines
2.6 KiB
HTML
Raw Normal View History

2019-04-04 12:48:53 +02:00
{% extends "layout.html" %}
{% block content %}
<div class="all">
<h1>These are all the files</h1>
{{ listingfiles }} <br>
{{ jsonfiles }} <br>
{{ listofdicts }} <br>
<div class="col-lg-3 col-md-4 col-xs-6 thumb">
{% for filename in listingfiles %}
{% if filename.lower().endswith(('.png', '.jpg', '.jpeg')) %}
2019-04-04 16:01:04 +02:00
<div><img class="img-responsive" src=" ../{{ filename }}">
2019-04-04 12:48:53 +02:00
{% for jsonfile in jsonfiles %}
{% if filename[0:9] == jsonfile[0:9] %}
<div class="descrip">
2019-04-04 16:01:04 +02:00
{{ jsonfile }}
2019-04-04 12:48:53 +02:00
{% for dict in listofdicts %}
{% if jsonfile[6:9]==dict["id"] %}
<p>{% for key, value in dict.items() %}
{{key}}: {{value}}<br>
{% endfor %}</p>
{% endif %}
{% endfor %}
2019-04-04 16:01:04 +02:00
</div></div>
2019-04-04 12:48:53 +02:00
{% break %}
{% endif %}
{% endfor %}
{% elif filename.lower().endswith(('.mp4')) %}
2019-04-04 16:01:04 +02:00
<div><video width="320" height="240" controls><source src="../{{filename}}" type="video/mp4">
2019-04-04 12:48:53 +02:00
Your browser does not support the video tag.
</video>
{% for jsonfile in jsonfiles %}
{% if filename[0:9] == jsonfile[0:9] %}
<div class="descrip">
2019-04-04 16:01:04 +02:00
{{ jsonfile }}
2019-04-04 12:48:53 +02:00
{% for dict in listofdicts %}
{% if jsonfile[6:9]==dict["id"] %}
<p>{% for key, value in dict.items() %}
{{key}}: {{value}}<br>
{% endfor %}</p>
{% endif %}
{% endfor %}
2019-04-04 16:01:04 +02:00
</div></div>
2019-04-04 12:48:53 +02:00
{% break %}
{% endif %}
{% endfor %}
{% elif filename.lower().endswith(('.mp3')) %}
2019-04-04 16:01:04 +02:00
<div><audio controls><source src="../{{filename}}" type="audio/mpeg">
2019-04-04 12:48:53 +02:00
Your browser does not support the audio tag.
</audio>
{% for jsonfile in jsonfiles %}
{% if filename[0:9] == jsonfile[0:9]%}
<div class="descrip">
2019-04-04 16:01:04 +02:00
{{ jsonfile }}
2019-04-04 12:48:53 +02:00
{% for dict in listofdicts %}
{% if jsonfile[6:9]==dict["id"] %}
<p>{% for key, value in dict.items() %}
{{key}}: {{value}}<br>
{% endfor %}</p>
{% endif %}
{% endfor %}
2019-04-04 16:01:04 +02:00
</div></div>
2019-04-04 12:48:53 +02:00
{% break %}
{% endif %}
{% endfor %}
{% endif %}
2019-04-04 16:01:04 +02:00
2019-04-04 12:48:53 +02:00
{% endfor %}
</div>
</div>
{% endblock %}