django-haystack和无尽的分页不能{%include page_template%}

时间:2014-02-10 19:47:54

标签: django-haystack django-endless-pagination

@page_template('voziladijelovi_dodatak.html')
def traziVozilaDijelovi(request):
    sqs = SearchQuerySet().filter(kategorije=('Vozila i Dijelovi')).facet('podkategorije').facet('drzava').facet('grad')
    view = FacetedSearchView(form_class=FacetedSearchForm, searchqueryset=sqs)

    return view(request)
模板{%include page_template%}中的

不起作用。

extra_context {u'page_template':u'voziladijelovi_dodatak.html'}遗失 create_response()

如何在视图中包含此内容

1 个答案:

答案 0 :(得分:1)

你的意思是:

view = FacetedSearchView(form_class=FacetedSearchForm, 
            searchqueryset=sqs, 
            template='voziladijelovi_dodatak.html')