category report

This commit is contained in:
2026-08-19 16:48:01 +02:00
parent c63e1070e0
commit f8b0d52ff7
6 changed files with 551 additions and 9 deletions

View File

@@ -235,6 +235,11 @@ const API = {
if (anonymize) params.set('anonymize', 'true');
if (groupByMonth) params.set('groupByMonth', 'true');
return fetch('/api/reports/revenue?' + params.toString()).then(r => r.json());
},
getCategoryRevenue: (from, to, groupByMonth = false) => {
const params = new URLSearchParams({ from, to });
if (groupByMonth) params.set('groupByMonth', 'true');
return fetch('/api/reports/category-revenue?' + params.toString()).then(r => r.json());
}
},