feat: add transaction statistics to TransactionsPage; implement reconciled and categorized percentage calculations, enhance card layout, and update UI components for improved data presentation
All checks were successful
Deploy with Docker Compose / deploy (push) Successful in 2m11s
All checks were successful
Deploy with Docker Compose / deploy (push) Successful in 2m11s
This commit is contained in:
@@ -41,13 +41,13 @@ export function OverviewCards({ data }: OverviewCardsProps) {
|
||||
const reconciled = data.transactions.filter((t) => t.isReconciled).length;
|
||||
const total = data.transactions.length;
|
||||
const reconciledPercent =
|
||||
total > 0 ? Math.round((reconciled / total) * 100) : 0;
|
||||
total > 0 ? ((reconciled / total) * 100).toFixed(2) : "0.00";
|
||||
|
||||
const categorized = data.transactions.filter(
|
||||
(t) => t.categoryId !== null
|
||||
).length;
|
||||
const categorizedPercent =
|
||||
total > 0 ? Math.round((categorized / total) * 100) : 0;
|
||||
total > 0 ? ((categorized / total) * 100).toFixed(2) : "0.00";
|
||||
|
||||
const formatCurrency = (amount: number) => {
|
||||
return new Intl.NumberFormat("fr-FR", {
|
||||
|
||||
Reference in New Issue
Block a user