2025-09-07 20:52:19 +02:00
|
|
|
from api.views import ping, secure_ping
|
2025-09-05 12:02:41 +02:00
|
|
|
from django.conf import settings
|
|
|
|
from django.contrib import admin
|
|
|
|
from django.urls import path, include
|
Add FontAwesome webfonts and update templates for Risiko Management
- Added FontAwesome webfont files: fa-brands-400.woff2, fa-regular-400.woff2, fa-solid-900.woff2, and fa-v4compatibility.woff2.
- Updated base.html to include FontAwesome stylesheet.
- Renamed the application title from "Risiko Management" to "ISO27001 Management".
- Enhanced navigation menu with dynamic active states for Dashboard, Statistics, Risks, Controls, and Incidents.
- Created new templates for dashboard, controls, incidents, risks, and statistics with breadcrumb navigation.
2025-09-07 23:07:56 +02:00
|
|
|
from django.shortcuts import render, redirect
|
2025-09-07 20:52:19 +02:00
|
|
|
from rest_framework import routers
|
|
|
|
from risks.views import RiskViewSet, ControlViewSet, ResidualRiskViewSet, UserViewSet, AuditViewSet
|
|
|
|
|
|
|
|
router = routers.DefaultRouter()
|
|
|
|
router.register(r"risks", RiskViewSet)
|
|
|
|
router.register(r"controls", ControlViewSet)
|
|
|
|
router.register(r"residual-risks", ResidualRiskViewSet)
|
|
|
|
router.register(r"users", UserViewSet)
|
|
|
|
router.register(r"logs", AuditViewSet)
|
2025-09-05 12:02:41 +02:00
|
|
|
|
|
|
|
urlpatterns = [
|
|
|
|
path("admin/", admin.site.urls),
|
2025-09-07 20:52:19 +02:00
|
|
|
path("api/ping/", ping), # Public healthcheck endpoint
|
|
|
|
path("api/secure-ping/", secure_ping), # Protected API endpoint
|
|
|
|
path("api/", include(router.urls)),
|
Add FontAwesome webfonts and update templates for Risiko Management
- Added FontAwesome webfont files: fa-brands-400.woff2, fa-regular-400.woff2, fa-solid-900.woff2, and fa-v4compatibility.woff2.
- Updated base.html to include FontAwesome stylesheet.
- Renamed the application title from "Risiko Management" to "ISO27001 Management".
- Enhanced navigation menu with dynamic active states for Dashboard, Statistics, Risks, Controls, and Incidents.
- Created new templates for dashboard, controls, incidents, risks, and statistics with breadcrumb navigation.
2025-09-07 23:07:56 +02:00
|
|
|
path("", include("risks.urls")),
|
|
|
|
path("risks/", include("risks.urls")),
|
2025-09-05 12:02:41 +02:00
|
|
|
]
|
|
|
|
|
2025-09-05 15:32:33 +02:00
|
|
|
# Add OIDC routes only if Single Sign-On is enabled
|
2025-09-05 12:02:41 +02:00
|
|
|
if settings.SSO_ENABLED:
|
|
|
|
urlpatterns += [
|
|
|
|
path("oidc/", include("mozilla_django_oidc.urls")),
|
2025-09-05 15:32:33 +02:00
|
|
|
]
|