"""efundburo URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/2.2/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: path('', views.home, name='home') Class-based views 1. Add an import: from other_app.views import Home 2. Add a URL to urlpatterns: path('', Home.as_view(), name='home') Including another URLconf 1. Import the include() function: from django.urls import include, path 2. Add a URL to urlpatterns: path('blog/', include('blog.urls')) """ from django.conf import settings from django.conf.urls import url, include from django.conf.urls.static import static from django.contrib import admin from django.urls import path import debug_toolbar from catalog import views from catalog.views import (AdsJSONView, ItemCommentsJSONView, ItemJSONView, LabelView, ModeJSONView, ParticipateJSONView, SearchJSONView, TagsJSONView, ItemLabelView, ItemBackLabelView, SitesJSONView) from wagtail.admin import urls as wagtailadmin_urls from wagtail.core import urls as wagtail_urls from wagtail.documents import urls as wagtaildocs_urls from django.conf.urls.i18n import i18n_patterns urlpatterns = [ path('admin/', admin.site.urls), # react frontend url(r'^$', views.index, name='index'), url(r'catalog/', views.catalog, name='catalog'), url(r'start/', views.catalog, name='start'), path('labels/create/', LabelView.as_view(), name='labels-create'), path('labels//', ItemLabelView.as_view(), name='labels-item'), path('labels//back/', ItemBackLabelView.as_view(), name='labels-item-back'), path('items/', SearchJSONView.as_view(), name='catalog'), path('tags/', TagsJSONView.as_view(), name='tags'), path('ads/', AdsJSONView.as_view(), name='ads'), path('mode/', ModeJSONView.as_view(), name='mode'), path('item//', ItemJSONView.as_view(), name='item'), path('item//comments/', ItemCommentsJSONView.as_view(), name='item-comments'), path('participate/', ParticipateJSONView.as_view(), name='participate'), path('cms/', include(wagtailadmin_urls)), path('documents/', include(wagtaildocs_urls)), path('__debug__/', include(debug_toolbar.urls)), ] + i18n_patterns( path('sites/', SitesJSONView.as_view(), name='sites'), path('', include(wagtail_urls)), ) + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)