fnp
/
edumed.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
ec3fc6c
)
various fixes
author
Radek Czajka
<radoslaw.czajka@nowoczesnapolska.org.pl>
Mon, 11 Feb 2013 11:30:36 +0000
(12:30 +0100)
committer
Radek Czajka
<radoslaw.czajka@nowoczesnapolska.org.pl>
Mon, 11 Feb 2013 11:30:36 +0000
(12:30 +0100)
catalogue/static/catalogue/css/lesson.css
patch
|
blob
|
history
catalogue/static/catalogue/css/lesson.scss
patch
|
blob
|
history
catalogue/templates/catalogue/lesson_detail.html
patch
|
blob
|
history
catalogue/templates/catalogue/snippets/lesson_link.html
patch
|
blob
|
history
catalogue/templates/catalogue/snippets/lesson_nav.html
patch
|
blob
|
history
catalogue/templatetags/catalogue_tags.py
patch
|
blob
|
history
edumed/static/css/base.css
patch
|
blob
|
history
edumed/static/css/base.scss
patch
|
blob
|
history
edumed/templates/base.html
patch
|
blob
|
history
diff --git
a/catalogue/static/catalogue/css/lesson.css
b/catalogue/static/catalogue/css/lesson.css
index
de122b8
..
df3f135
100644
(file)
--- a/
catalogue/static/catalogue/css/lesson.css
+++ b/
catalogue/static/catalogue/css/lesson.css
@@
-227,6
+227,11
@@
em.person {
.activity .info .materials h1 {
background: url(/static/img/icons/activity-tools.png) 0 0 no-repeat; }
.activity .info .materials h1 {
background: url(/static/img/icons/activity-tools.png) 0 0 no-repeat; }
+.lista .paragraph {
+ margin: .3em 0; }
+.lista li {
+ margin: .75em 0; }
+
.clearboth {
clear: both; }
.clearboth {
clear: both; }
diff --git
a/catalogue/static/catalogue/css/lesson.scss
b/catalogue/static/catalogue/css/lesson.scss
index
1378c20
..
a1627bc
100755
(executable)
--- a/
catalogue/static/catalogue/css/lesson.scss
+++ b/
catalogue/static/catalogue/css/lesson.scss
@@
-286,6
+286,15
@@
em.person {
}
}
}
}
+.lista {
+ .paragraph {
+ margin: .3em 0;
+ }
+ li {
+ margin: .75em 0;
+ }
+}
+
.clearboth {
clear: both;
.clearboth {
clear: both;
diff --git
a/catalogue/templates/catalogue/lesson_detail.html
b/catalogue/templates/catalogue/lesson_detail.html
index
8cf7bf4
..
237e723
100755
(executable)
--- a/
catalogue/templates/catalogue/lesson_detail.html
+++ b/
catalogue/templates/catalogue/lesson_detail.html
@@
-55,11
+55,11
@@
{% if object.dc.relations %}
<section class="section-minor">
<h1>Powiązane lekcje</h1>
{% if object.dc.relations %}
<section class="section-minor">
<h1>Powiązane lekcje</h1>
+ <ul class="link-list link-list-colored">
{% for uri in object.dc.relations %}
{% for uri in object.dc.relations %}
- <ul class="link-list">
<li>{% lesson_link uri %}</li>
<li>{% lesson_link uri %}</li>
- </ul>
{% endfor %}
{% endfor %}
+ </ul>
</section>
{% endif %}
</section>
{% endif %}
diff --git
a/catalogue/templates/catalogue/snippets/lesson_link.html
b/catalogue/templates/catalogue/snippets/lesson_link.html
index
15b8cf0
..
749b4e1
100755
(executable)
--- a/
catalogue/templates/catalogue/snippets/lesson_link.html
+++ b/
catalogue/templates/catalogue/snippets/lesson_link.html
@@
-1
+1
@@
-<a href="{{ lesson.get_absolute_url }}">{{ lesson }}</a>
+{% if lesson %}<a href="{{ lesson.get_absolute_url }}">{{ lesson }}</a>{% endif %}
diff --git
a/catalogue/templates/catalogue/snippets/lesson_nav.html
b/catalogue/templates/catalogue/snippets/lesson_nav.html
index
742004f
..
a2ff5ba
100755
(executable)
--- a/
catalogue/templates/catalogue/snippets/lesson_nav.html
+++ b/
catalogue/templates/catalogue/snippets/lesson_nav.html
@@
-2,8
+2,10
@@
<h1>
{% if root %}
<a href="{{ root.get_absolute_url }}">{{ root }}</a>
<h1>
{% if root %}
<a href="{{ root.get_absolute_url }}">{{ root }}</a>
+{% elif lesson.type == 'synthetic' %}
+ <a href="{% url 'catalogue_lessons' %}">Lekcje syntetyczne ze wszystkich tematów</a>
{% else %}
{% else %}
- <a href="{% url 'catalogue_lessons' %}">
Wszystkie działy
</a>
+ <a href="{% url 'catalogue_lessons' %}">
Inne
</a>
{% endif %}
</h1>
{% endif %}
</h1>
@@
-12,8
+14,11
@@
<li>
{% if item == lesson %}
<strong>{{ item }}</strong>
<li>
{% if item == lesson %}
<strong>{{ item }}</strong>
+ {% if mark_level and item.level.slug == 'liceum' %} (poziom zaawansowany){% endif %}
{% else %}
{% else %}
- <a href="{{ item.get_absolute_url }}">{{ item }}</a>
+ <a href="{{ item.get_absolute_url }}">{{ item }}
+ {% if mark_level and item.level.slug == 'liceum' %} (poziom zaawansowany){% endif %}
+ </a>
{% endif %}
</li>
{% endfor %}
{% endif %}
</li>
{% endfor %}
diff --git
a/catalogue/templatetags/catalogue_tags.py
b/catalogue/templatetags/catalogue_tags.py
index
09113d9
..
fd1fc62
100755
(executable)
--- a/
catalogue/templatetags/catalogue_tags.py
+++ b/
catalogue/templatetags/catalogue_tags.py
@@
-37,19
+37,25
@@
def section_box(section):
def lesson_nav(lesson):
if lesson.type == 'course':
root = lesson.section
def lesson_nav(lesson):
if lesson.type == 'course':
root = lesson.section
- siblings = root.lesson_set.filter(type='course')
+ siblings = root.lesson_set.filter(type='course', level=lesson.level)
+ mark_level = False
else:
root = None
siblings = Lesson.objects.filter(type=lesson.type)
else:
root = None
siblings = Lesson.objects.filter(type=lesson.type)
+ mark_level = True
return {
"lesson": lesson,
"root": root,
"siblings": siblings,
return {
"lesson": lesson,
"root": root,
"siblings": siblings,
+ "mark_level": mark_level
}
@register.inclusion_tag("catalogue/snippets/lesson_link.html")
def lesson_link(uri):
}
@register.inclusion_tag("catalogue/snippets/lesson_link.html")
def lesson_link(uri):
- return {'lesson': Lesson.objects.get(slug=WLURI(uri).slug)}
+ try:
+ return {'lesson': Lesson.objects.get(slug=WLURI(uri).slug)}
+ except Lesson.DoesNotExist:
+ return {}
@register.filter
def person_list(persons):
@register.filter
def person_list(persons):
diff --git
a/edumed/static/css/base.css
b/edumed/static/css/base.css
index
c256472
..
89c34d6
100644
(file)
--- a/
edumed/static/css/base.css
+++ b/
edumed/static/css/base.css
@@
-190,6
+190,9
@@
footer.main {
.link-list a:hover {
color: #ed7831; }
.link-list a:hover {
color: #ed7831; }
+.link-list-colored a {
+ color: #ed7831; }
+
.plain {
margin: 0;
padding: 0;
.plain {
margin: 0;
padding: 0;
diff --git
a/edumed/static/css/base.scss
b/edumed/static/css/base.scss
index
3bf409f
..
4d7e8a7
100644
(file)
--- a/
edumed/static/css/base.scss
+++ b/
edumed/static/css/base.scss
@@
-224,6
+224,13
@@
footer.main {
color: $oranji;
}
}
color: $oranji;
}
}
+.link-list-colored {
+ a {
+ color: $oranji;
+ }
+}
+
+
.plain {
margin: 0;
padding: 0;
.plain {
margin: 0;
padding: 0;
diff --git
a/edumed/templates/base.html
b/edumed/templates/base.html
index
e744135
..
ca28197
100644
(file)
--- a/
edumed/templates/base.html
+++ b/
edumed/templates/base.html
@@
-43,7
+43,7
@@
<li><a class="menu-lekcje" href="{% url "catalogue_lessons" %}">Lekcje</a></li>
<li><a class="menu-kompetencje" href="{% url "curriculum" %}">Kompetencje</a></li>
<li><a class="menu-wspolpraca" href="{% url "info" "wspolpraca/" %}">Współpraca</a></li>
<li><a class="menu-lekcje" href="{% url "catalogue_lessons" %}">Lekcje</a></li>
<li><a class="menu-kompetencje" href="{% url "curriculum" %}">Kompetencje</a></li>
<li><a class="menu-wspolpraca" href="{% url "info" "wspolpraca/" %}">Współpraca</a></li>
- <li><a class="menu-szkolenia" href="{% url "info" "
szkolenia/" %}">Szkolenia
</a></li>
+ <li><a class="menu-szkolenia" href="{% url "info" "
konkurs/" %}">Konkurs
</a></li>
<li><a class="menu-wesprzyj" href="{% url "info" "wesprzyj/" %}">Wesprzyj nas</a></li>
<li><a class="menu-o-nas" href="{% url "info" "o-nas/" %}">O nas</a></li>
<li><a class="menu-kontakt" href="{% url "info" "kontakt/" %}">Kontakt</a></li>
<li><a class="menu-wesprzyj" href="{% url "info" "wesprzyj/" %}">Wesprzyj nas</a></li>
<li><a class="menu-o-nas" href="{% url "info" "o-nas/" %}">O nas</a></li>
<li><a class="menu-kontakt" href="{% url "info" "kontakt/" %}">Kontakt</a></li>