fix: settings plans query — fetch all plans including inactive #4

Merged
kibin merged 1 commits from fix/settings-plans-include-inactive into main 2026-03-31 06:02:25 +00:00
Showing only changes of commit 7c2ab351a8 - Show all commits

View File

@@ -406,7 +406,7 @@ function PlansSettings() {
queryKey: ["plans"],
queryFn: async () => {
try {
const res = await api.get<Plan[] | { data: Plan[] }>("/api/v1/plans");
const res = await api.get<Plan[] | { data: Plan[] }>("/api/v1/plans?includeInactive=true");
const d = res.data;
return Array.isArray(d) ? d : (d as { data: Plan[] }).data ?? [];
} catch {