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:
fab117d
)
filter empty identifiers for curriculum
author
Jan Szejko
<janek37@gmail.com>
Tue, 31 Jan 2017 14:04:19 +0000
(15:04 +0100)
committer
Jan Szejko
<janek37@gmail.com>
Tue, 31 Jan 2017 14:04:19 +0000
(15:04 +0100)
curriculum/templatetags/curriculum_tags.py
patch
|
blob
|
history
diff --git
a/curriculum/templatetags/curriculum_tags.py
b/curriculum/templatetags/curriculum_tags.py
index
cc37d0e
..
983ceac
100755
(executable)
--- a/
curriculum/templatetags/curriculum_tags.py
+++ b/
curriculum/templatetags/curriculum_tags.py
@@
-22,6
+22,8
@@
def competence(texts, level):
@register.inclusion_tag("curriculum/snippets/curriculum.html")
def curriculum(identifiers):
@register.inclusion_tag("curriculum/snippets/curriculum.html")
def curriculum(identifiers):
+ # shouldn't be needed, but is
+ identifiers = [id for id in identifiers if id]
try:
currs = [Curriculum.objects.get(identifier__iexact=identifier.replace(' ', ''))
for identifier in identifiers]
try:
currs = [Curriculum.objects.get(identifier__iexact=identifier.replace(' ', ''))
for identifier in identifiers]