bmc_hub/app/modules/orders/frontend/views.py
Christian 3cddb71cec feat: Add Technician Dashboard V1, V2, and V3 with enhanced UI and functionality
- Introduced Technician Dashboard V1 (tech_v1_overview.html) with KPI cards and new cases overview.
- Implemented Technician Dashboard V2 (tech_v2_workboard.html) featuring a workboard layout for daily tasks and opportunities.
- Developed Technician Dashboard V3 (tech_v3_table_focus.html) with a power table for detailed case management.
- Created a dashboard selector page (technician_dashboard_selector.html) for easy navigation between dashboard versions.
- Added user dashboard preferences migration (130_user_dashboard_preferences.sql) to store default dashboard paths.
- Enhanced sag_sager table with assigned group ID (131_sag_assignment_group.sql) for better case management.
- Updated sag_subscriptions table to include cancellation rules and billing dates (132_subscription_cancellation.sql, 134_subscription_billing_dates.sql).
- Implemented subscription staging for CRM integration (136_simply_subscription_staging.sql).
- Added a script to move time tracking section in detail view (move_time_section.py).
- Created a test script for subscription processing (test_subscription_processing.py).
2026-02-17 08:29:05 +01:00

31 lines
1.0 KiB
Python

import logging
from fastapi import APIRouter, Request
from fastapi.responses import HTMLResponse
from fastapi.templating import Jinja2Templates
logger = logging.getLogger(__name__)
router = APIRouter()
templates = Jinja2Templates(directory="app")
@router.get("/ordre/create/new", response_class=HTMLResponse)
async def ordre_create(request: Request):
"""Opret ny ordre (gammel funktionalitet)."""
return templates.TemplateResponse("modules/orders/templates/create.html", {"request": request})
@router.get("/ordre/{draft_id}", response_class=HTMLResponse)
async def ordre_detail(request: Request, draft_id: int):
"""Detaljeret visning af en specifik ordre."""
return templates.TemplateResponse("modules/orders/templates/detail.html", {
"request": request,
"draft_id": draft_id
})
@router.get("/ordre", response_class=HTMLResponse)
async def ordre_index(request: Request):
"""Liste over alle ordre drafts."""
return templates.TemplateResponse("modules/orders/templates/list.html", {"request": request})