feat(savings): Add savings module with categories, transactions, recurring plans
- Categories: regular, deposits, credits, recurring, multi-user, accounts - Transactions: deposits and withdrawals with user tracking - Recurring plans: monthly payment obligations per user - Stats: overdues calculation with allocation algorithm - Excludes is_account categories from total sums - Documentation: docs/SAVINGS.md
This commit is contained in:
21
internal/model/habit_freeze.go
Normal file
21
internal/model/habit_freeze.go
Normal file
@@ -0,0 +1,21 @@
|
||||
package model
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
||||
type HabitFreeze struct {
|
||||
ID int64 `db:"id" json:"id"`
|
||||
HabitID int64 `db:"habit_id" json:"habit_id"`
|
||||
UserID int64 `db:"user_id" json:"user_id"`
|
||||
StartDate time.Time `db:"start_date" json:"start_date"`
|
||||
EndDate time.Time `db:"end_date" json:"end_date"`
|
||||
Reason string `db:"reason" json:"reason"`
|
||||
CreatedAt time.Time `db:"created_at" json:"created_at"`
|
||||
}
|
||||
|
||||
type CreateHabitFreezeRequest struct {
|
||||
StartDate string `json:"start_date"`
|
||||
EndDate string `json:"end_date"`
|
||||
Reason string `json:"reason,omitempty"`
|
||||
}
|
||||
Reference in New Issue
Block a user