54 lines
2.3 KiB
Python
54 lines
2.3 KiB
Python
#!/usr/bin/env python
|
|
# -*- coding: utf-8 -*-
|
|
|
|
from django.urls import path
|
|
from lostplaces.views import (
|
|
HomeView,
|
|
FlatView,
|
|
OSMMapView,
|
|
PlaceDetailView,
|
|
PlaceListView,
|
|
PlaceCreateView,
|
|
PlaceUpdateView,
|
|
PlaceDeleteView,
|
|
PlaceTagDeleteView,
|
|
PlaceTagSubmitView,
|
|
PlaceFavoriteView,
|
|
PlaceUnfavoriteView,
|
|
PlaceVisitCreateView,
|
|
PlaceVisitDeleteView,
|
|
PlaceImageCreateView,
|
|
PlaceImageDeleteView,
|
|
ExternalLinkCreateView,
|
|
ExternalLinkDeleteView,
|
|
ExplorerProfileView,
|
|
ExplorerProfileUpdateView
|
|
)
|
|
|
|
urlpatterns = [
|
|
path('', HomeView.as_view(), name='lostplaces_home'),
|
|
path('flat/<slug:slug>/', FlatView, name='flatpage'),
|
|
path('osm/', OSMMapView.as_view(), name='osm'),
|
|
|
|
path('explorer/<int:explorer_id>/', ExplorerProfileView.as_view(), name='explorer_profile'),
|
|
path('explorer/update/', ExplorerProfileUpdateView.as_view(), name='explorer_profile_update'),
|
|
|
|
path('place/', PlaceListView.as_view(), name='place_list'),
|
|
path('place/<int:pk>/', PlaceDetailView.as_view(), name='place_detail'),
|
|
path('place/create/', PlaceCreateView.as_view(), name='place_create'),
|
|
path('place/update/<int:pk>/', PlaceUpdateView.as_view(), name='place_edit'),
|
|
path('place/delete/<int:pk>/', PlaceDeleteView.as_view(), name='place_delete'),
|
|
path('place/tag/create/<int:tagged_id>/', PlaceTagSubmitView.as_view(), name='place_tag_submit'),
|
|
path('place/tag/delete/<int:tagged_id>/<int:tag_id>/', PlaceTagDeleteView.as_view(), name='place_tag_delete'),
|
|
path('place/fav/create/<int:place_id>/', PlaceFavoriteView.as_view(), name='place_favorite'),
|
|
path('place/fav/delete/<int:place_id>/', PlaceUnfavoriteView.as_view(), name='place_unfavorite'),
|
|
path('place/visit/create/<int:place_id>/', PlaceVisitCreateView.as_view(), name='place_visit_create'),
|
|
path('place/visit/delete/<int:place_id>/', PlaceVisitDeleteView.as_view(), name='place_visit_delete'),
|
|
|
|
path('place_image/create/<int:place_id>/', PlaceImageCreateView.as_view(), name='place_image_create'),
|
|
path('place_image/delete/<int:pk>/', PlaceImageDeleteView.as_view(), name='place_image_delete'),
|
|
|
|
path('external_link/create/<int:place_id>/', ExternalLinkCreateView.as_view(), name='external_link_create'),
|
|
path('external_link/delete/<int:pk>/', ExternalLinkDeleteView.as_view(), name='external_link_delete')
|
|
]
|