diff --git a/BudgetApp/Components/Layout/NavMenu.razor b/BudgetApp/Components/Layout/NavMenu.razor index 7a17eb9..a205ebf 100644 --- a/BudgetApp/Components/Layout/NavMenu.razor +++ b/BudgetApp/Components/Layout/NavMenu.razor @@ -39,6 +39,12 @@ +
Manage your financial accounts, balances and currencies.
Create and organise categories to classify your transactions.
Guides and tips to help you get the most out of Budgeteer.
An overview of your balances, recent and upcoming transactions.
@if (data is null) { diff --git a/BudgetApp/Components/Pages/Reports.razor b/BudgetApp/Components/Pages/Reports.razor new file mode 100644 index 0000000..33b9ac8 --- /dev/null +++ b/BudgetApp/Components/Pages/Reports.razor @@ -0,0 +1,372 @@ +@page "/reports" +@attribute [Authorize] +@inject TransactionService TransactionService +@inject AccountService AccountService +@inject CategoryService CategoryService +@inject AuthenticationStateProvider AuthStateProvider +@inject IJSRuntime JS +@implements IAsyncDisposable +@rendermode InteractiveServer + +Visual breakdown of your spending and income by category for a specified time period.
+ +@if (loading) +{ +Loading...
+} +else if (accounts.Count == 0) +{ +Add some accounts and transactions to see your spending reports.
+No expenses in this period.
+ } + else + { +No income in this period.
+ } + else + { +No transactions in this period.
+ } + else + { +No transactions in this period.
+ } + else + { +| Category | +Income | +Expenses | +Net | +
|---|---|---|---|
| @row.Icon @row.Name | +@currencySymbol@row.Income.ToString("N2") | +@currencySymbol@row.Expense.ToString("N2") | ++ @currencySymbol@row.Net.ToString("N2") + | +
| Total | +@currencySymbol@categorySummary.Sum(r => r.Income).ToString("N2") | +@currencySymbol@categorySummary.Sum(r => r.Expense).ToString("N2") | + @{ var totalNet = categorySummary.Sum(r => r.Net); } ++ @currencySymbol@totalNet.ToString("N2") + | +
Change your password, reset your data or delete your account.
@* ── Change Password ── *@Record, edit and manage your income and expenses.