summaryrefslogtreecommitdiff
path: root/src/account.h
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-11-02 01:39:18 -0500
committerJohn Wiegley <johnw@newartisans.com>2009-11-02 01:40:07 -0500
commit3a0879aff0b1ea0037098ae4f602b92719ff9a84 (patch)
tree7a4ff9ee85a5bd50e627c9b7b233246f55e566da /src/account.h
parent4db60bb46429ced93770afe69b42477c03c47e72 (diff)
downloadfork-ledger-3a0879aff0b1ea0037098ae4f602b92719ff9a84.tar.gz
fork-ledger-3a0879aff0b1ea0037098ae4f602b92719ff9a84.tar.bz2
fork-ledger-3a0879aff0b1ea0037098ae4f602b92719ff9a84.zip
Added "reported posts" into account xdata
This is necessary because sometimes, a post from one account will get reported as though it were in another account (this happens with --budget, to show child account postings within their parent account). In that case, the account needs to remember which postings have been reported as being within it, so that it can add these amounts to its own total in the balance report.
Diffstat (limited to 'src/account.h')
-rw-r--r--src/account.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/account.h b/src/account.h
index ce0a7a66..c8f6bdbd 100644
--- a/src/account.h
+++ b/src/account.h
@@ -159,6 +159,7 @@ public:
std::set<string> payees_referenced;
optional<posts_list::const_iterator> last_post;
+ optional<posts_list::const_iterator> last_reported_post;
details_t()
: calculated(false),
@@ -176,8 +177,9 @@ public:
void update(post_t& post, bool gather_all = false);
};
- details_t self_details;
- details_t family_details;
+ details_t self_details;
+ details_t family_details;
+ posts_list reported_posts;
std::list<sort_value_t> sort_values;