git-svn-id: https://django-pagination.googlecode.com/svn/trunk@25
7f1efe38-554e-0410-b69d-
834cb44da2d5
register = template.Library()
register = template.Library()
-DEFAULT_PAGINATION = 20
-DEFAULT_WINDOW = 4
-DEFAULT_ORPHANS = 0
+DEFAULT_PAGINATION = getattr(settings, 'PAGINATION_DEFAULT_PAGINATION', 20)
+DEFAULT_WINDOW = getattr(settings, 'PAGINATION_DEFAULT_WINDOW', 4)
+DEFAULT_ORPHANS = getattr(settings, 'PAGINATION_DEFAULT_ORPHANS', 0)
def do_autopaginate(parser, token):
"""
def do_autopaginate(parser, token):
"""
except KeyError:
return {}
register.inclusion_tag('pagination/pagination.html', takes_context=True)(paginate)
except KeyError:
return {}
register.inclusion_tag('pagination/pagination.html', takes_context=True)(paginate)
-register.tag('autopaginate', do_autopaginate)
\ No newline at end of file
+register.tag('autopaginate', do_autopaginate)