diff options
author | John Wiegley <johnw@newartisans.com> | 2009-02-15 21:14:54 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2009-02-15 21:14:54 -0400 |
commit | 780ce4a5d0f313c60f8b51a00d29f997381691d0 (patch) | |
tree | 52e90ae25d014a7f3936e0ceaa61e2d2e2a957d7 /src/global.cc | |
parent | 484b498c1406124cf122e49a0f0477b278284593 (diff) | |
download | fork-ledger-780ce4a5d0f313c60f8b51a00d29f997381691d0.tar.gz fork-ledger-780ce4a5d0f313c60f8b51a00d29f997381691d0.tar.bz2 fork-ledger-780ce4a5d0f313c60f8b51a00d29f997381691d0.zip |
Normalized handling of several report options
Diffstat (limited to 'src/global.cc')
-rw-r--r-- | src/global.cc | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/src/global.cc b/src/global.cc index b2dc24fc..598aee48 100644 --- a/src/global.cc +++ b/src/global.cc @@ -382,25 +382,12 @@ void global_scope_t::normalize_report_options(const string& verb) } } + if (! rep.HANDLED(empty)) + rep.HANDLER(display_).append("amount|(!xact&total)"); + if (verb[0] != 'b' && verb[0] != 'r') rep.HANDLER(base).on(); - // Setup the default value for the display predicate - - if (! rep.HANDLED(display_)) { - if (verb[0] == 'b') { - if (! rep.HANDLED(empty)) - rep.append_display_predicate("total"); - } - else if (verb == "equity") { - // jww (2008-08-14): ??? - rep.append_display_predicate("amount_expr"); - } - else if (verb[0] == 'r' && ! rep.HANDLED(empty)) { - rep.append_display_predicate("amount"); - } - } - if (rep.HANDLED(period_) && ! rep.HANDLED(sort_all_)) rep.HANDLER(sort_entries_).on(); } |