equal
deleted
inserted
replaced
21 '"Pawel Solyga" <pawel.solyga@gmail.com>', |
21 '"Pawel Solyga" <pawel.solyga@gmail.com>', |
22 ] |
22 ] |
23 |
23 |
24 |
24 |
25 import soc.logic |
25 import soc.logic |
|
26 from soc.logic import models |
26 from soc.views import simple |
27 from soc.views import simple |
27 from soc.views import helper |
28 from soc.views import helper |
28 from soc.views.helper import access |
29 from soc.views.helper import access |
29 import soc.views.helper.lists |
30 import soc.views.helper.lists |
30 import soc.views.helper.responses |
31 import soc.views.helper.responses |
47 |
48 |
48 offset, limit = helper.lists.cleanListParameters( |
49 offset, limit = helper.lists.cleanListParameters( |
49 offset=request.GET.get('offset'), limit=request.GET.get('limit')) |
50 offset=request.GET.get('offset'), limit=request.GET.get('limit')) |
50 |
51 |
51 # Fetch one more to see if there should be a 'next' link |
52 # Fetch one more to see if there should be a 'next' link |
52 sponsors = soc.logic.sponsor_logic.getForLimitAndOffset(limit + 1, offset=offset) |
53 sponsors = models.sponsor.logic.getForLimitAndOffset(limit + 1, offset=offset) |
53 |
54 |
54 context['pagination_form'] = helper.lists.makePaginationForm(request, limit) |
55 context['pagination_form'] = helper.lists.makePaginationForm(request, limit) |
55 |
56 |
56 list_templates = {'list_main': 'soc/list/list_main.html', |
57 list_templates = {'list_main': 'soc/list/list_main.html', |
57 'list_pagination': 'soc/list/list_pagination.html', |
58 'list_pagination': 'soc/list/list_pagination.html', |