from django.urls import path, include from rest_framework_simplejwt.views import TokenObtainPairView, TokenRefreshView from . import views from api.views import CreateUserView, ChangePasswordView urlpatterns = [ # Authentication path('user/register/', CreateUserView.as_view(), name='register'), path('user/password/change/', ChangePasswordView.as_view(), name='password_change'), path('token/', TokenObtainPairView.as_view(), name='token_obtain_pair'), path('token/refresh/', TokenRefreshView.as_view(), name='token_refresh'), path('auth/', include('rest_framework.urls')), # Accounts path('accounts/', views.AccountsView.as_view(), name='accounts'), path('accounts/status/', views.GetAccountStatus.as_view(), name='account_status'), path('accounts/rate/', views.GetAccountRate.as_view(), name='account_rate'), path('accounts/revenue/', views.GetAccountRevenue.as_view(), name='account_revenue'), path('accounts/supplies/', views.SupplyRequest.as_view(), name='account_supplies'), # Service Days path('days/', views.ServiceDaysView.as_view(), name='all_service_days'), path('days//', views.AccountServiceDaysView.as_view(), name='service_days'), # Stores path('stores/', views.StoresView.as_view(), name='stores'), path('stores//', views.StoreView.as_view(), name='store'), # Projects path('projects/', views.ProjectsView.as_view(), name='projects'), path('projects/punch/', views.CreatePunchlist.as_view(), name='punchlist'), path('projects/close/', views.CloseProject.as_view(), name='close_project'), # Service Visits path('visits/', views.ServiceVisitsView.as_view(), name='visits'), path('visits/close/', views.CloseVisitView.as_view(), name='close_visit'), # Calendar path('calendar/', views.CreateCalendarEvents.as_view(), name='google-calendar'), ]