Files
cmhub/apps/portal/urls.py
T

44 lines
1.7 KiB
Python

from allauth.account.views import LoginView, LogoutView, SignupView
from django.urls import path
from .views import (
ApiKeyDeleteView,
ApiKeyListCreateView,
DashboardView,
DeviceCredentialListView,
DeviceCredentialRevokeView,
HomeView,
ModelCatalogView,
MigrationConfirmView,
RechargePageView,
RechargeRecordListView,
SubscriptionPageView,
UsageRecordListView,
)
urlpatterns = [
path("", HomeView.as_view(), name="portal-home"),
path("signup", SignupView.as_view(), name="portal-signup"),
path("login", LoginView.as_view(), name="portal-login"),
path("logout", LogoutView.as_view(), name="portal-logout"),
path("dashboard", DashboardView.as_view(), name="portal-dashboard"),
path("apikeys", ApiKeyListCreateView.as_view(), name="portal-apikeys"),
path("apikeys/<int:pk>/delete", ApiKeyDeleteView.as_view(), name="portal-apikey-delete"),
path("models", ModelCatalogView.as_view(), name="portal-models"),
path("recharge", RechargePageView.as_view(), name="portal-recharge"),
path("subscription", SubscriptionPageView.as_view(), name="portal-subscription"),
path(
"migration/confirm/<uuid:request_id>",
MigrationConfirmView.as_view(),
name="portal-migration-confirm",
),
path("migration/devices", DeviceCredentialListView.as_view(), name="portal-device-credentials"),
path(
"migration/credentials/<int:pk>/revoke",
DeviceCredentialRevokeView.as_view(),
name="portal-device-credential-revoke",
),
path("records/recharge", RechargeRecordListView.as_view(), name="portal-recharge-records"),
path("records/usage", UsageRecordListView.as_view(), name="portal-usage-records"),
]