diff options
-rw-r--r-- | src/xact.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/xact.cc b/src/xact.cc index a54da81a..ec1d372c 100644 --- a/src/xact.cc +++ b/src/xact.cc @@ -780,6 +780,14 @@ void auto_xact_t::extend_xact(xact_base_t& xact, parse_context_t& context) // the automated xact's one. post_t * new_post = new post_t(account, amt); new_post->copy_details(*post); + + // A Cleared transaction implies all of its automatic posting are cleared + // CPR 2012/10/23 + if(xact.state() == item_t::CLEARED){ + DEBUG("xact.extend.cleared", "CLEARED"); + new_post->set_state(item_t::CLEARED); + } + new_post->add_flags(ITEM_GENERATED); new_post->account = journal->register_account(account->fullname(), new_post, |