from api.views import ListCreateSurvey, RetrieveUpdateDestroySurvey, UserDetail, ChangePassword, RegisterUser, \ ListCreateQuestion, RetrieveUpdateDestroyQuestion, TakeSurvey, MyDetail surveys = [ path('', ListCreateSurvey.as_view()), path('<int:pk>', RetrieveUpdateDestroySurvey.as_view()), ] questions = [ path('', ListCreateQuestion.as_view()), path('<int:pk>', RetrieveUpdateDestroyQuestion.as_view()), ] token = [ path('obtain', TokenObtainPairView.as_view(), name='token_obtain_pair'), path('refresh', TokenRefreshView.as_view(), name='token_refresh'), path('verify', TokenVerifyView.as_view(), name='token_verify'), ] urlpatterns = [ path('take-survey/<int:pk>', TakeSurvey.as_view()), path('surveys/', include(surveys)), path('questions/', include(questions)), path('token/', include(token)), path('account', MyDetail.as_view()), path('account/<int:pk>', UserDetail.as_view()), path('register', RegisterUser.as_view()), path('set-password', ChangePassword.as_view()) ]
url(r'^api/v1/aggregate/', AggregateByTime.as_view()), url(r'^api/v1/aggregate_dtype/', AggregateByDtype.as_view()), url(r'^api/v1/aggregate_area/', AreaAggregate.as_view()), url(r'^api/v2/create_field_report/', api_views.CreateFieldReport.as_view()), url(r'^api/v2/update_field_report/(?P<pk>\d+)/', api_views.UpdateFieldReport.as_view()), url(r'^get_auth_token', GetAuthToken.as_view()), url(r'^api/v2/update_subscriptions/', UpdateSubscriptionPreferences.as_view()), url(r'^api/v2/add_subscription/', AddSubscription.as_view()), url(r'^api/v2/del_subscription/', DelSubscription.as_view()), url(r'^register', NewRegistration.as_view()), url(r'^sendperform', FormSent.as_view()), url(r'^editperform', FormEdit.as_view()), url(r'^sendperdraft', DraftSent.as_view()), url(r'^sendperoverview', OverviewSent.as_view()), url(r'^sendperworkplan', WorkPlanSent.as_view()), url(r'^api/v2/del_perworkplan', DelWorkPlan.as_view()), url(r'^api/v2/del_peroverview', DelOverview.as_view()), url(r'^api/v2/del_perdraft', DelDraft.as_view()), url(r'^verify_email', VerifyEmail.as_view()), url(r'^validate_user', ValidateUser.as_view()), url(r'^change_password', ChangePassword.as_view()), url(r'^recover_password', RecoverPassword.as_view()), url(r'^show_username', ShowUsername.as_view()), url(r'^api/v2/', include(router.urls)), url(r'^docs/', include_docs_urls(title='IFRC Go API')), url(r'^tinymce/', include('tinymce.urls')), url(r'^admin/', RedirectView.as_view(url='/')), url(r'^', admin.site.urls), url(r'^favicon\.ico$',RedirectView.as_view(url='/static/favicon.ico')), ]
from django.conf.urls import url, include from django.contrib import admin from api.views import UserList, UserDetail, ProfileList, ProfileDetail, JobPostingList, \ JobPostingDetail, JobApplicationList, JobApplicationDetail, InviteViaEmail, ProfileRecommendations, \ EducationDescriptionList, EducationDescriptionDetail, EmploymentDescriptionList, EmploymentDescriptionDetail, \ SkillList, SkillDetail, CompanyList, CompanyDetail, ForgottenPasswordEmail, ResetPassword, Search, RegisterConnection, \ ConnectionList, ProfileImageList, ProfileApplicationIDs, ProfileApplicationList, FeedPostList, UserJobPostingsList, \ ChangePassword, DeleteConnection urlpatterns = [ url(r'^users/$', UserList.as_view()), url(r'^users/(?P<username>[a-zA-Z][a-zA-Z0-9_]+)/$', UserDetail.as_view()), url(r'^users/(?P<username>[a-zA-Z][a-zA-Z0-9_]+)/change-password/$', ChangePassword.as_view()), url(r'^profiles/$', ProfileList.as_view()), url(r'^profiles/(?P<username>[a-zA-Z][a-zA-Z0-9_]+)/$', ProfileDetail.as_view()), url(r'^profiles/(?P<username>[a-zA-Z][a-zA-Z0-9_]+)/recommendations/$', ProfileRecommendations.as_view()), url(r'^profiles/(?P<username>[a-zA-Z][a-zA-Z0-9_]+)/application_ids/$', ProfileApplicationIDs.as_view()), url(r'^jobs/$', JobPostingList.as_view()), url(r'^jobs/(?P<job_id>[0-9]+)/$', JobPostingDetail.as_view()), url(r'^jobs/(?P<job_id>[0-9]+)/applications/$', JobApplicationList.as_view()), url(r'^jobs/(?P<job_id>[0-9]+)/applications/(?P<application_id>[0-9]+)/$', JobApplicationDetail.as_view()), url(r'^send-invite/$', InviteViaEmail.as_view()), url(r'^forgot-password/$', ForgottenPasswordEmail.as_view()), url(r'^reset-password/$', ResetPassword.as_view()),