'use client'; import Link from 'next/link'; import { useQuery } from '@tanstack/react-query'; import { apiFetch } from '../../../../lib/api'; import type { Goal, Decision, Task } from '../../../../lib/api'; import { useSession } from '../../../../components/session-provider'; const B = '/dashboard'; interface Organization { id: string; name: string; country?: string | null; createdAt: string; } interface Opportunity { id: string; source: string; probability?: string | null; expiresAt?: string | null; } function StatCard({ label, value, sub, href, color = 'text-ink' }: { label: string; value: number | string; sub?: string; href?: string; color?: string; }) { const inner = (
{label}
{value}
{sub &&{sub}
}Metrici cheie — organizații, taskuri, obiective, decizii, oportunități
Niciun obiectiv înregistrat
) : (Nicio decizie înregistrată
) : ({org.name}
{org.country &&{org.country}
}{new Date(org.createdAt).toLocaleDateString('ro-RO', { day: 'numeric', month: 'short', year: 'numeric' })}