fnp
/
wolnelektury.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
ad39c25
)
Bug fixes.
author
Radek Czajka
<radekczajka@nowoczesnapolska.org.pl>
Mon, 22 Sep 2014 13:26:33 +0000
(15:26 +0200)
committer
Radek Czajka
<radekczajka@nowoczesnapolska.org.pl>
Mon, 22 Sep 2014 13:26:33 +0000
(15:26 +0200)
apps/catalogue/templates/catalogue/book_detail.html
patch
|
blob
|
history
apps/catalogue/views.py
patch
|
blob
|
history
apps/funding/templates/funding/offer_list.html
patch
|
blob
|
history
apps/polls/templatetags/polls_tags.py
patch
|
blob
|
history
diff --git
a/apps/catalogue/templates/catalogue/book_detail.html
b/apps/catalogue/templates/catalogue/book_detail.html
index
398a43c
..
7e8128f
100644
(file)
--- a/
apps/catalogue/templates/catalogue/book_detail.html
+++ b/
apps/catalogue/templates/catalogue/book_detail.html
@@
-22,7
+22,7
@@
<section class="see-also" style="display: inline-block;">
<h1>{% trans "Other versions" %}:</h1>
{% for rel in book.other_versions %}
<section class="see-also" style="display: inline-block;">
<h1>{% trans "Other versions" %}:</h1>
{% for rel in book.other_versions %}
- {% ssi_include 'book_mini' pk=rel.pk %}
+ {% ssi_include '
catalogue_
book_mini' pk=rel.pk %}
{% endfor %}
</section>
{% endif %}
{% endfor %}
</section>
{% endif %}
diff --git
a/apps/catalogue/views.py
b/apps/catalogue/views.py
index
e5514f0
..
20518e8
100644
(file)
--- a/
apps/catalogue/views.py
+++ b/
apps/catalogue/views.py
@@
-59,7
+59,7
@@
def catalogue(request, as_json=False):
collections = models.Collection.objects.all()
def render_tag_list(tags):
collections = models.Collection.objects.all()
def render_tag_list(tags):
- render_to_string('catalogue/tag_list.html', tag_list(tags))
+ re
turn re
nder_to_string('catalogue/tag_list.html', tag_list(tags))
def render_split(with_books, with_pictures):
ctx = {}
def render_split(with_books, with_pictures):
ctx = {}
@@
-212,7
+212,7
@@
def tagged_object_list(request, tags=''):
all_books = models.Book.tagged.with_all(tags)
if shelf_is_set:
books = all_books.order_by('sort_key_author', 'title')
all_books = models.Book.tagged.with_all(tags)
if shelf_is_set:
books = all_books.order_by('sort_key_author', 'title')
- pictures = Picture
s
.objects.none()
+ pictures = Picture.objects.none()
related_book_tags = models.Tag.objects.usage_for_queryset(
books, counts=True).exclude(
category='set').exclude(pk__in=tags_pks)
related_book_tags = models.Tag.objects.usage_for_queryset(
books, counts=True).exclude(
category='set').exclude(pk__in=tags_pks)
@@
-531,7
+531,10
@@
def json_tags_starting_with(request, callback=None):
result = [prefix, tags_list]
else:
result = {"matches": tags_list}
result = [prefix, tags_list]
else:
result = {"matches": tags_list}
- return JsonResponse(result, callback)
+ response = JsonResponse(result, safe=False)
+ if callback:
+ response.content = callback + "(" + response.content + ");"
+ return response
# =========
# =========
diff --git
a/apps/funding/templates/funding/offer_list.html
b/apps/funding/templates/funding/offer_list.html
index
feb175d
..
e8088bf
100644
(file)
--- a/
apps/funding/templates/funding/offer_list.html
+++ b/
apps/funding/templates/funding/offer_list.html
@@
-1,7
+1,7
@@
{% extends "base.html" %}
{% load url from future %}
{% load i18n %}
{% extends "base.html" %}
{% load url from future %}
{% load i18n %}
-{% load
funding_tags
%}
+{% load
ssi_include from ssify
%}
{% load pagination_tags %}
{% block titleextra %}{% trans "All fundraisers" %}{% endblock %}
{% load pagination_tags %}
{% block titleextra %}{% trans "All fundraisers" %}{% endblock %}
@@
-24,15
+24,16
@@
<h2>{% trans "Previous fundraisers:" %}</h2>
{% endif %}
<h2>{% trans "Previous fundraisers:" %}</h2>
{% endif %}
- {%
funding offer link=1 show_title_calling=False
%}
+ {%
ssi_include 'funding_list_bar' pk=offer.pk
%}
<div class="white-box normal-text">
{% if is_current %}
<h3>{% trans "Help free the book!" %}</h3>
{{ offer.description|safe }}
{% endif %}
<div class="white-box normal-text">
{% if is_current %}
<h3>{% trans "Help free the book!" %}</h3>
{{ offer.description|safe }}
{% endif %}
- {% offer_status offer %}
- {% offer_status_more offer %}
+ {% ssi_include 'funding_status' pk=offer.pk %}
+ {% ssi_include 'funding_status_more' pk=offer.pk %}
+
</div>
{% if is_current and not forloop.last %}
</div>
{% if is_current and not forloop.last %}
diff --git
a/apps/polls/templatetags/polls_tags.py
b/apps/polls/templatetags/polls_tags.py
index
fffa780
..
38619c1
100644
(file)
--- a/
apps/polls/templatetags/polls_tags.py
+++ b/
apps/polls/templatetags/polls_tags.py
@@
-18,5
+18,6
@@
def poll(context, poll, show_results=True, redirect_to=''):
form=form,
voted_already=voted_already,
vote_count=poll.vote_count,
form=form,
voted_already=voted_already,
vote_count=poll.vote_count,
- show_results=show_results
+ show_results=show_results,
+ request=context.get('request'),
)
)