-
-
- setStartDate(e.target.value)} />
-
-
-
- setEndDate(e.target.value)} />
-
+
+
+ setCurrency(e.target.value)} />
-
- {existingBudgets.length > 0 && (
-
-
-
-
- )}
-
diff --git a/frontend/src/i18n/de.json b/frontend/src/i18n/de.json
index 7df286d..f5440c9 100644
--- a/frontend/src/i18n/de.json
+++ b/frontend/src/i18n/de.json
@@ -49,9 +49,10 @@
"endDate": "Enddatum",
"currency": "Waehrung",
"carryover": "Uebertrag",
- "copyFrom": "Vom vorherigen kopieren",
"selectBudget": "Budget auswaehlen",
- "setup": "Einrichtung"
+ "generate": "Aus Vorlage erstellen",
+ "month": "Monat",
+ "generating": "Wird erstellt..."
},
"category": {
"create": "Kategorie erstellen",
diff --git a/frontend/src/i18n/en.json b/frontend/src/i18n/en.json
index 0b9b3af..2bb48be 100644
--- a/frontend/src/i18n/en.json
+++ b/frontend/src/i18n/en.json
@@ -49,9 +49,10 @@
"endDate": "End Date",
"currency": "Currency",
"carryover": "Carryover",
- "copyFrom": "Copy from previous",
"selectBudget": "Select Budget",
- "setup": "Setup"
+ "generate": "Generate from Template",
+ "month": "Month",
+ "generating": "Generating..."
},
"category": {
"create": "Create Category",
diff --git a/frontend/src/lib/api.ts b/frontend/src/lib/api.ts
index a30f2a4..be1ebc5 100644
--- a/frontend/src/lib/api.ts
+++ b/frontend/src/lib/api.ts
@@ -135,8 +135,6 @@ export const budgets = {
update: (id: string, data: Partial
) =>
request(`/budgets/${id}`, { method: 'PUT', body: JSON.stringify(data) }),
delete: (id: string) => request(`/budgets/${id}`, { method: 'DELETE' }),
- copyFrom: (id: string, srcId: string) =>
- request(`/budgets/${id}/copy-from/${srcId}`, { method: 'POST' }),
generate: (data: { month: string; currency: string }) =>
request('/budgets/generate', { method: 'POST', body: JSON.stringify(data) }),
}
diff --git a/frontend/src/pages/DashboardPage.test.tsx b/frontend/src/pages/DashboardPage.test.tsx
index f48f6f9..03a6ca6 100644
--- a/frontend/src/pages/DashboardPage.test.tsx
+++ b/frontend/src/pages/DashboardPage.test.tsx
@@ -11,8 +11,7 @@ vi.mock('@/lib/api', () => ({
budgets: {
list: vi.fn().mockResolvedValue([]),
get: vi.fn().mockResolvedValue(null),
- create: vi.fn().mockResolvedValue({}),
- copyFrom: vi.fn().mockResolvedValue({}),
+ generate: vi.fn().mockResolvedValue({}),
},
budgetItems: {
update: vi.fn().mockResolvedValue({}),