from django.urls import path from django.urls import reverse_lazy from django.views.generic import RedirectView from django.views.i18n import JavaScriptCatalog from . import views urlpatterns = [ path("", RedirectView.as_view(url=reverse_lazy("map")), name="index"), path("map", views.Map.as_view(), name="map"), path("case-study/create", views.CreateCaseStudySelector.as_view(), name="create"), path( "case-study/create/short", views.CreateShortCaseStudy.as_view(), name="short-form", ), path( "case-study/create/long", views.CreateLongCaseStudy.as_view(), name="long-form" ), path( "case-study/create/poi", views.CreatePointOfInterest.as_view(), name="point-of-interest-form", ), path( "case-study/create/success", views.CreateCaseStudySuccess.as_view(), name="form-success", ), path("case-study/edit/", views.EditCaseStudy.as_view(), name="edit"), path("case-study/draft", views.DraftsAPI.as_view(), name="drafts"), # This should be last so that the above options will be tried first! path("case-study/", views.ViewCaseStudyDetail.as_view(), name="detail"), # API path("jsi18n", JavaScriptCatalog.as_view(), name="javascript-catalogue"), path( "srs-autocomplete", views.SpatialRefSysAutocomplete.as_view(), name="srs-autocomplete", ), ]