# -*- coding:utf-8 -* # # Copyright 2016,2017 # - Skia # - Sli # # Ce fichier fait partie du site de l'Association des Étudiants de l'UTBM, # http://ae.utbm.fr. # # This program is free software; you can redistribute it and/or modify it under # the terms of the GNU General Public License a published by the Free Software # Foundation; either version 3 of the License, or (at your option) any later # version. # # This program is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more # details. # # You should have received a copy of the GNU General Public License along with # this program; if not, write to the Free Sofware Foundation, Inc., 59 Temple # Place - Suite 330, Boston, MA 02111-1307, USA. # # from django.urls import path, re_path, register_converter from core.views import * from core.converters import ( FourDigitYearConverter, TwoDigitMonthConverter, BooleanStringConverter, ) register_converter(FourDigitYearConverter, "yyyy") register_converter(TwoDigitMonthConverter, "mm") register_converter(BooleanStringConverter, "bool") urlpatterns = [ path("", index, name="index"), path("to_markdown/", ToMarkdownView.as_view(), name="to_markdown"), path("notifications/", NotificationList.as_view(), name="notification_list"), path("notification//", notification, name="notification"), # Search path("search/", search_view, name="search"), path("search_json/", search_json, name="search_json"), path("search_user/", search_user_json, name="search_user"), # Login and co path("login/", SithLoginView.as_view(), name="login"), path("logout/", logout, name="logout"), path("password_change/", SithPasswordChangeView.as_view(), name="password_change"), path( "password_change//", password_root_change, name="password_root_change", ), path( "password_change/done/", SithPasswordChangeDoneView.as_view(), name="password_change_done", ), path("password_reset/", SithPasswordResetView.as_view(), name="password_reset"), path( "password_reset/done/", SithPasswordResetDoneView.as_view(), name="password_reset_done", ), path( r"reset///", SithPasswordResetConfirmView.as_view(), name="password_reset_confirm", ), path( "reset/done/", SithPasswordResetCompleteView.as_view(), name="password_reset_complete", ), path("register/", register, name="register"), # Group handling path("group/", GroupListView.as_view(), name="group_list"), path("group/new/", GroupCreateView.as_view(), name="group_new"), path("group//", GroupEditView.as_view(), name="group_edit"), path( "group//delete/", GroupDeleteView.as_view(), name="group_delete", ), path( "group//detail/", GroupTemplateView.as_view(), name="group_detail", ), # User views path("user/", UserListView.as_view(), name="user_list"), path( "user//mini/", UserMiniView.as_view(), name="user_profile_mini", ), path("user//", UserView.as_view(), name="user_profile"), path( "user//pictures/", UserPicturesView.as_view(), name="user_pictures", ), path( "user//godfathers/", UserGodfathersView.as_view(), name="user_godfathers", ), path( "user//godfathers/tree/", UserGodfathersTreeView.as_view(), name="user_godfathers_tree", ), path( "user//godfathers/tree/pict/", UserGodfathersTreePictureView.as_view(), name="user_godfathers_tree_pict", ), path( "user//godfathers///delete/", delete_user_godfather, name="user_godfathers_delete", ), path( "user//edit/", UserUpdateProfileView.as_view(), name="user_edit", ), path( "user//profile_upload/", UserUploadProfilePictView.as_view(), name="user_profile_upload", ), path("user//clubs/", UserClubView.as_view(), name="user_clubs"), path( "user//prefs/", UserPreferencesView.as_view(), name="user_prefs", ), path( "user//groups/", UserUpdateGroupView.as_view(), name="user_groups", ), path("user/tools/", UserToolsView.as_view(), name="user_tools"), path( "user//account/", UserAccountView.as_view(), name="user_account", ), path( "user//account///", UserAccountDetailView.as_view(), name="user_account_detail", ), path("user//stats/", UserStatsView.as_view(), name="user_stats"), path( "user//gift/create/", GiftCreateView.as_view(), name="user_gift_create", ), path( "user//gift/delete//", GiftDeleteView.as_view(), name="user_gift_delete", ), # File views re_path(r"^file/(?Ppopup)?$", FileListView.as_view(), name="file_list"), re_path( r"^file/(?P[0-9]+)/(?Ppopup)?$", FileView.as_view(), name="file_detail", ), re_path( r"^file/(?P[0-9]+)/edit/(?Ppopup)?$", FileEditView.as_view(), name="file_edit", ), re_path( r"^file/(?P[0-9]+)/prop/(?Ppopup)?$", FileEditPropView.as_view(), name="file_prop", ), re_path( r"^file/(?P[0-9]+)/delete/(?Ppopup)?$", FileDeleteView.as_view(), name="file_delete", ), path("file/moderation/", FileModerationView.as_view(), name="file_moderation"), path( "file//moderate/", FileModerateView.as_view(), name="file_moderate", ), path("file//download/", send_file, name="download"), # Page views path("page/", PageListView.as_view(), name="page_list"), path("page/create/", PageCreateView.as_view(), name="page_new"), path( "page//delete/", PageDeleteView.as_view(), name="page_delete", ), path( "page//edit/", PageEditView.as_view(), name="page_edit", ), path( "page//prop/", PagePropView.as_view(), name="page_prop", ), path( "page//hist/", PageHistView.as_view(), name="page_hist", ), path( "page//rev//", PageRevView.as_view(), name="page_rev", ), path( "page//", PageView.as_view(), name="page", ), ]