feat: recurring expenses and reports

This commit is contained in:
juancwu 2026-02-14 17:00:15 +00:00
commit 9e6ff67a87
23 changed files with 2943 additions and 56 deletions

23
internal/model/report.go Normal file
View file

@ -0,0 +1,23 @@
package model
import "time"
type DailySpending struct {
Date time.Time `db:"date"`
TotalCents int `db:"total_cents"`
}
type MonthlySpending struct {
Month string `db:"month"`
TotalCents int `db:"total_cents"`
}
type SpendingReport struct {
ByTag []*TagExpenseSummary
DailySpending []*DailySpending
MonthlySpending []*MonthlySpending
TopExpenses []*ExpenseWithTagsAndMethod
TotalIncome int
TotalExpenses int
NetBalance int
}