From f7833f76b5f9555b0d95d23d47fc886a3528a335 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20St=C4=99pniowski?= Date: Wed, 16 Dec 2009 01:29:51 +0100 Subject: [PATCH] =?utf8?q?Dodanie=20aplikacji=20do=20umieszczania=20pomocn?= =?utf8?q?iczych=20materia=C5=82=C3=B3w=20dla=20nauczycieli.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- wolnelektury/settings.py | 1 + wolnelektury/static/css/master.css | 56 ++++++++++++++++- .../templates/catalogue/main_page.html | 5 ++ .../lessons/ajax_document_detail.html | 11 ++++ .../templates/lessons/document_detail.html | 21 +++++++ .../templates/lessons/document_list.html | 63 +++++++++++++++++++ wolnelektury/urls.py | 1 + 7 files changed, 157 insertions(+), 1 deletion(-) create mode 100644 wolnelektury/templates/lessons/ajax_document_detail.html create mode 100644 wolnelektury/templates/lessons/document_detail.html create mode 100644 wolnelektury/templates/lessons/document_list.html diff --git a/wolnelektury/settings.py b/wolnelektury/settings.py index 722cd93ab..fcecc1a54 100644 --- a/wolnelektury/settings.py +++ b/wolnelektury/settings.py @@ -104,6 +104,7 @@ INSTALLED_APPS = [ 'chunks', 'compress', 'catalogue', + 'lessons', ] CACHE_BACKEND = 'locmem:///?max_entries=3000' diff --git a/wolnelektury/static/css/master.css b/wolnelektury/static/css/master.css index d7d741ac5..c62bcbc06 100644 --- a/wolnelektury/static/css/master.css +++ b/wolnelektury/static/css/master.css @@ -655,4 +655,58 @@ div.shown-tags p, div.all-tags p { color: #FFF; background-color: #900; text-decoration: none; -} \ No newline at end of file +} + +/* =========== */ +/* = Lessons = */ +/* =========== */ +#lessons { + margin-top: 2.5em; +} + +#document-list { + width: 380px; + float: left; +} + +#document-list ol { + margin: 0; + padding: 0; + list-style: none; +} + +#document-list li a { + padding: 0.5em; + background-color: #FFF; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + border-radius: 3px; +/* font-size: 1.2em;*/ + font-weight: bold; + width: 370px; + margin-bottom: 0.25em; + display: block; +} + +#document-list li a:hover, #document-list li a.active { + text-decoration: none; + background-color: #EEE; +} + +#document-list-body #document-detail { + margin-left: 390px; +} + +#document-detail { + width: 480px; +} + +#document-detail h2 { + margin: 0.75em 0 0.75em 0; +} + +#document-list-body #document-detail .download { + float: right; + margin: 0; + padding: 0 +} diff --git a/wolnelektury/templates/catalogue/main_page.html b/wolnelektury/templates/catalogue/main_page.html index 5e36eadda..756bd74a9 100644 --- a/wolnelektury/templates/catalogue/main_page.html +++ b/wolnelektury/templates/catalogue/main_page.html @@ -36,6 +36,11 @@

Stwórz własny zestaw lektur. Możesz się nim później podzielić z innymi, przesyłając im link do Twojej półki.

Aby zarządzać swoimi półkami, musisz się .

{% endif %} +
+

Materiały pomocnicze dla nauczycieli

+

Scenariusze lekcji i inne pomysły na wykorzytanie serwisu WolneLektury.pl podczas nauczania.

+

Zobacz więcej ⇒

+

Czytamy Słuchając to profesjonalne nagrania tekstów literackich z naszego zbioru dostępne na wolnej licencji w formatach MP3, Ogg Vorbis oraz w systemie DAISY.

diff --git a/wolnelektury/templates/lessons/ajax_document_detail.html b/wolnelektury/templates/lessons/ajax_document_detail.html new file mode 100644 index 000000000..93bccb397 --- /dev/null +++ b/wolnelektury/templates/lessons/ajax_document_detail.html @@ -0,0 +1,11 @@ +
+

Pobierz {% if object.author %}(autor: {{ object.author }}){% endif %}

+

{{ object.title }}

+ {% if object.slideshare_id %} + + + {% endif %} + {% if object.description %} +

{{ object.description|urlize|linebreaks }}

+ {% endif %} +
\ No newline at end of file diff --git a/wolnelektury/templates/lessons/document_detail.html b/wolnelektury/templates/lessons/document_detail.html new file mode 100644 index 000000000..9ee604e90 --- /dev/null +++ b/wolnelektury/templates/lessons/document_detail.html @@ -0,0 +1,21 @@ +{% extends 'base.html' %} + +{% block title %}{{ object.title }} w WolneLektury.pl{% endblock %} + +{% block body %} +

{{ object.title }}

+
+

{{ form.q }} lub wróć do listy materiałów

+
+ +
+

Pobierz {% if object.author %}(autor: {{ object.author }}){% endif %}

+ {% if object.slideshare_id %} + + + {% endif %} + {% if object.description %} +

{{ object.description|urlize|linebreaks }}

+ {% endif %} +
+{% endblock body %} \ No newline at end of file diff --git a/wolnelektury/templates/lessons/document_list.html b/wolnelektury/templates/lessons/document_list.html new file mode 100644 index 000000000..1a5ab01d4 --- /dev/null +++ b/wolnelektury/templates/lessons/document_list.html @@ -0,0 +1,63 @@ +{% extends "base.html" %} +{% load catalogue_tags chunks %} + +{% block bodyid %}document-list-body{% endblock %} + +{% block title %}Materiały pomocnicze dla nauczycieli w WolneLektury.pl{% endblock %} + +{% block extrahead %} + +{% endblock extrahead %} +{% block body %} +

Materiały pomocnicze dla nauczycieli

+
+

{{ form.q }} lub wróć do strony głównej

+
+ +
+
    + {% for object in object_list %} +
  1. {{ object }}
  2. + {% endfor %} +
+
+
+
+{% endblock %} + \ No newline at end of file diff --git a/wolnelektury/urls.py b/wolnelektury/urls.py index 199441424..9d8d23fca 100644 --- a/wolnelektury/urls.py +++ b/wolnelektury/urls.py @@ -13,6 +13,7 @@ admin.autodiscover() urlpatterns = patterns('', url(r'^katalog/', include('catalogue.urls')), + url(r'^materialy/', include('lessons.urls')), # Static pages url(r'^wolontariat/$', 'django.views.generic.simple.direct_to_template', -- 2.20.1