from django.urls import path from . import views app_name = 'mensaviewer' urlpatterns = [ # routes for overview path('', views.flensburg, name='flensburg'), path('custom-location', views.custom, name='custom'), # raw create routes path('add-location/', views.LocationCreateView.as_view(), name='location_create'), path('add-news-article/', views.NewsArticleCreateView.as_view(), name='news_create'), path('add-menu/', views.MenuCreateView.as_view(), name='menu_create'), path('add-comment/', views.CommentCreateView.as_view(), name='comment_create'), # relation-dependent create routes path('location//add-news-article/', views.NewsArticleCreateView.as_view(), name='news_add'), path('location//add-menu/', views.MenuCreateView.as_view(), name='menu_add'), path('menu//add-comment/', views.CommentCreateView.as_view(), name='comment_add'), # list-view routes path('locations/', views.LocationListView.as_view(), name='location_list'), path('news-articles/', views.NewsArticleListView.as_view(), name='news_list'), path('menus/', views.MenuListView.as_view(), name='menu_list'), path('comments/', views.CommentListView.as_view(), name='comment_list'), # detail-view routes path('location//', views.LocationDetailView.as_view(), name='location_detail'), path('news-article//', views.NewsArticleDetailView.as_view(), name='news_detail'), path('menu//', views.MenuDetailView.as_view(), name='menu_detail'), path('comment//', views.CommentDetailView.as_view(), name='comment_detail'), # update-view routes path('location//edit/', views.LocationUpdateView.as_view(), name='location_update'), path('news-artice//edit/', views.NewsArticleUpdateView.as_view(), name='news_update'), path('menu//edit/', views.MenuUpdateView.as_view(), name='menu_update'), path('comment//edit/', views.CommentUpdateView.as_view(), name='comment_update'), # delete-view routes path('location//delete/', views.LocationDeleteView.as_view(), name='location_delete'), path('news-artice//delete/', views.NewsArticleDeleteView.as_view(), name='news_delete'), path('menu//delete/', views.MenuDeleteView.as_view(), name='menu_delete'), path('comment//delete/', views.CommentDeleteView.as_view(), name='comment_delete'), # like / dislike routes path('menu//like/', views.like, name='like'), path('menu//dislike/', views.dislike, name='dislike'), ]