From 157be90714685d0dc9d45320539300c7f8b4f58e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20Zapke-Gru=CC=88ndemann?= Date: Mon, 23 Jan 2012 23:17:35 +0100 Subject: add image for project --- .../projects/templates/projects/project_detail.html | 10 ++++++++++ .../projects/templates/projects/project_image.html | 14 ++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 sublab_project/projects/templates/projects/project_image.html (limited to 'sublab_project/projects/templates') diff --git a/sublab_project/projects/templates/projects/project_detail.html b/sublab_project/projects/templates/projects/project_detail.html index 600b79c..5c0a6dd 100644 --- a/sublab_project/projects/templates/projects/project_detail.html +++ b/sublab_project/projects/templates/projects/project_detail.html @@ -1,9 +1,19 @@ {% extends 'base.html' %} +{% load thumbnail %} {% block title %}Projekt: {{ object.name }}{% endblock %} {% block content %}

Projekt: {{ object.name }}

+ {% if object.image %} +
+ + {% thumbnail object.image "200" upscale=False as image %} + + {% endthumbnail %} + +
+ {% endif %} {{ object.description_html|safe }} {% if object.contact_email %}

E-Mail: {{ object.contact_email }}

diff --git a/sublab_project/projects/templates/projects/project_image.html b/sublab_project/projects/templates/projects/project_image.html new file mode 100644 index 0000000..65e82f3 --- /dev/null +++ b/sublab_project/projects/templates/projects/project_image.html @@ -0,0 +1,14 @@ +{% extends 'base.html' %} +{% load thumbnail %} + +{% block title %}Bild: {{ object.name }}{% endblock %} + +{% block content %} +

Bild: {{ object.name }}

+
+ {% thumbnail object.image "820" upscale=False as image %} + + {% endthumbnail %} +
+

Zurück zum Projekt

+{% endblock content %} -- cgit v1.2.1