Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

app.py 558B

12345678910111213141516171819
  1. from django.conf.urls import patterns, url
  2. from oscar.core.application import Application
  3. from oscar.apps.search.views import MultiFacetedSearchView
  4. from oscar.apps.search.forms import MultiFacetedSearchForm
  5. class SearchApplication(Application):
  6. name = 'search'
  7. search_view = MultiFacetedSearchView
  8. def get_urls(self):
  9. urlpatterns = patterns('',
  10. url(r'^$', self.search_view(form_class=MultiFacetedSearchForm), name='search'),
  11. )
  12. return self.post_process_urls(urlpatterns)
  13. application = SearchApplication()