Blame view

src/core/pyros_django/api/urls.py 1.04 KB
98621b46   Alexis Koralewski   add DRF, pyros ap...
1
2
3
from django.urls import path, include
from . import views
from rest_framework.authtoken.views import obtain_auth_token
4b904014   Alexis Koralewski   Add view to get s...
4
from rest_framework import routers, renderers
98621b46   Alexis Koralewski   add DRF, pyros ap...
5
6
7
8

router = routers.DefaultRouter()
router.register(r'users', views.UserViewSet)
router.register(r'sequences', views.SequenceViewSet)
c2589779   Alexis Koralewski   Adding API views ...
9
10
11
router.register(r'albums', views.AlbumViewSet)
router.register(r'plans', views.PlanViewSet)
router.register(r'full_sequences', views.FullSequenceViewSet)
995a2ae6   Alexis Koralewski   adding scientific...
12
router.register(r'scientific_programs', views.ScientificProgramViewSet)
33c8da07   Alexis Koralewski   Adding SP_Period ...
13
router.register(r'sp_period', views.SPPeriodViewSet)
0d6aa42f   Alexis Koralewski   Add vuejs in agen...
14
router.register(r'agent_survey', views.AgentSurveyViewSet)
e49ef271   Alexis Koralewski   Add vue to render...
15
router.register(r'agent_cmd', views.AgentCmdViewSet)
995a2ae6   Alexis Koralewski   adding scientific...
16

98621b46   Alexis Koralewski   add DRF, pyros ap...
17
18
urlpatterns = [
    path('', include(router.urls)),
0318e3c9   Alexis Koralewski   Add tests for F05...
19
    path('logout/', views.user_logout, name='logout'),
98621b46   Alexis Koralewski   add DRF, pyros ap...
20
    path('api-token-auth/', obtain_auth_token, name='api_token_auth'),
0318e3c9   Alexis Koralewski   Add tests for F05...
21
22
    path("submit_sequence", views.submit_sequence_with_json,
         name="api_submit_sequence"),
e49ef271   Alexis Koralewski   Add vue to render...
23
    path("agent_cmd/<str:agent_name>",views.AgentCmdViewSet.as_view({'get': 'list'}))
0318e3c9   Alexis Koralewski   Add tests for F05...
24
] + router.urls