fix(overdracht): Filter op rapportages i.p.v. encounters + report types
Overdracht dashboard: - Patiënten nu gefilterd op rapportages (laatste 24u) i.p.v. encounters - Reports-block toont correcte type labels en kleuren Rapportage module: - Alle report types toegevoegd aan centrale lib/types/report.ts - Quick actions met alle 8 rapportage types en icons - Default type gewijzigd naar 'voortgang' 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1,19 +1,22 @@
|
||||
'use client'
|
||||
|
||||
import { FileText, ClipboardList } from 'lucide-react'
|
||||
import { FileText, ClipboardList, Activity, AlertTriangle, Pill, TrendingUp, Phone, Zap } from 'lucide-react'
|
||||
import { cn } from '@/lib/utils'
|
||||
import type { ReportType } from '@/lib/types/report'
|
||||
|
||||
// Re-export for backwards compatibility
|
||||
export type { ReportType } from '@/lib/types/report'
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
// Types
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
export type ReportType = 'vrije_notitie' | 'behandeladvies'
|
||||
|
||||
interface QuickAction {
|
||||
id: string
|
||||
label: string
|
||||
icon: typeof FileText
|
||||
type: ReportType
|
||||
color?: string
|
||||
}
|
||||
|
||||
export interface QuickActionsProps {
|
||||
@@ -32,8 +35,14 @@ export interface QuickActionsProps {
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
const QUICK_ACTIONS: QuickAction[] = [
|
||||
{ id: 'vrije-notitie', label: '+ Vrije notitie', icon: FileText, type: 'vrije_notitie' },
|
||||
{ id: 'behandeladvies', label: '+ Behandeladvies', icon: ClipboardList, type: 'behandeladvies' },
|
||||
{ id: 'voortgang', label: 'Voortgang', icon: TrendingUp, type: 'voortgang', color: 'emerald' },
|
||||
{ id: 'observatie', label: 'Observatie', icon: Activity, type: 'observatie', color: 'blue' },
|
||||
{ id: 'medicatie', label: 'Medicatie', icon: Pill, type: 'medicatie', color: 'purple' },
|
||||
{ id: 'incident', label: 'Incident', icon: AlertTriangle, type: 'incident', color: 'red' },
|
||||
{ id: 'contact', label: 'Contact', icon: Phone, type: 'contact', color: 'amber' },
|
||||
{ id: 'crisis', label: 'Crisis', icon: Zap, type: 'crisis', color: 'red' },
|
||||
{ id: 'vrije-notitie', label: 'Vrije notitie', icon: FileText, type: 'vrije_notitie', color: 'slate' },
|
||||
{ id: 'behandeladvies', label: 'Behandeladvies', icon: ClipboardList, type: 'behandeladvies', color: 'indigo' },
|
||||
]
|
||||
|
||||
// ─────────────────────────────────────────────────────────────────────────────
|
||||
|
||||
@@ -49,7 +49,7 @@ export function RapportageWorkspaceV2({
|
||||
linkedEncounterId,
|
||||
}: RapportageWorkspaceV2Props) {
|
||||
const [reports, setReports] = useState(initialReports)
|
||||
const [selectedType, setSelectedType] = useState<ReportType>('vrije_notitie')
|
||||
const [selectedType, setSelectedType] = useState<ReportType>('voortgang')
|
||||
const [selectedReport, setSelectedReport] = useState<Report | null>(null)
|
||||
const [isModalOpen, setIsModalOpen] = useState(false)
|
||||
const [duplicateContent, setDuplicateContent] = useState<string | null>(null)
|
||||
|
||||
Reference in New Issue
Block a user