Basic functionality ready.
This commit is contained in:
66
viewer/templates/gallery_view.html
Normal file
66
viewer/templates/gallery_view.html
Normal file
@@ -0,0 +1,66 @@
|
||||
{% load static %}
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta name="viewport" content="width=device-width, height=device-height" />
|
||||
<title>
|
||||
Folder: {{request.path}}
|
||||
</title>
|
||||
<link href="{% static 'css/styles.css' %}" rel="stylesheet">
|
||||
</head>
|
||||
<body class="background">
|
||||
<div class="centered-container">
|
||||
<a href="/gallery/">
|
||||
<img src="{% static 'imgs/gohome.png' %}">
|
||||
</a>
|
||||
<a href="..">
|
||||
<img src="{% static 'imgs/back.png' %}">
|
||||
</a>
|
||||
</div>
|
||||
{% if images|length > 0 %}
|
||||
<div class="centered-container">
|
||||
<h1>
|
||||
Files
|
||||
</h1>
|
||||
</div>
|
||||
<div class=grid-container>
|
||||
<div class="grid">
|
||||
{% for image in images %}
|
||||
<div class="column">
|
||||
<a href="{{image.path}}">
|
||||
<img src="{{image.thumbnail}}">
|
||||
</a>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if subdirs|length > 0 %}
|
||||
<div class="centered-container">
|
||||
<h1>
|
||||
Sub-directories
|
||||
</h1>
|
||||
</div>
|
||||
<div class=grid-container>
|
||||
<div class="grid">
|
||||
{% for dir in subdirs%}
|
||||
<div class="column">
|
||||
{% if request.path == '/gallery/' %}
|
||||
<a href="{{dir.name}}">
|
||||
{% else %}
|
||||
<a href="{{request.path}}{{dir.name}}">
|
||||
{% endif %}
|
||||
<div class="grid-icon">
|
||||
<img src="{% static 'imgs/folder-pictures.png' %}">
|
||||
</div>
|
||||
<span>
|
||||
{{dir.name}}
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
</body>
|
||||
</html>
|
Reference in New Issue
Block a user