From 03861eb7dbaa81b158c0710777615859996d2cb0 Mon Sep 17 00:00:00 2001 From: Herculino Trotta Date: Sun, 7 Sep 2025 21:35:29 -0300 Subject: [PATCH] Updated Transaction Rules (markdown) --- Transaction-Rules.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Transaction-Rules.md b/Transaction-Rules.md index f23a1f9..c34c5e3 100644 --- a/Transaction-Rules.md +++ b/Transaction-Rules.md @@ -165,8 +165,9 @@ The filter uses Django's ORM filter syntax (e.g., `account__id=5`, `description_ The returned object has the following properties: * `.sum`: The sum of the `amount` for the filtered transactions. -* `.balance`: The absolute balance (total income - total expenses). +* `.balance`: The absolute balance (total income - total expenses), always a positive number. * `.raw_balance`: The raw balance (can be negative). +* `.exclude(filter)`: Exclude one or mode results (e.g. `description='Coffee'` will exclude any transaction with the description 'Coffee' from the original filter), Example: `transactions(account_id=account_id, date__month=date.month).sum` returns the sum of all transactions in the same account and month as the triggering transaction.