diff options
author | John Wiegley <johnw@newartisans.com> | 2009-10-25 04:37:11 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2009-10-25 05:01:47 -0400 |
commit | fc84eeb358f13b7c2b2668917692da26af001901 (patch) | |
tree | cfc4540c1b7805a17425675c1143d7a2d748b42f /src/report.h | |
parent | 588f2ef2f51d7bdf209820bfb244034863601939 (diff) | |
download | fork-ledger-fc84eeb358f13b7c2b2668917692da26af001901.tar.gz fork-ledger-fc84eeb358f13b7c2b2668917692da26af001901.tar.bz2 fork-ledger-fc84eeb358f13b7c2b2668917692da26af001901.zip |
Rewrote the way date and time I/O is managed
Diffstat (limited to 'src/report.h')
-rw-r--r-- | src/report.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/report.h b/src/report.h index 71dc4ca2..5921a154 100644 --- a/src/report.h +++ b/src/report.h @@ -218,6 +218,7 @@ public: HANDLER(current).report(out); HANDLER(daily).report(out); HANDLER(date_format_).report(out); + HANDLER(datetime_format_).report(out); HANDLER(depth_).report(out); HANDLER(deviation).report(out); HANDLER(display_).report(out); @@ -412,10 +413,8 @@ public: parent->HANDLER(period_).on(string("--daily"), "daily"); }); - OPTION__(report_t, date_format_, // -y - CTOR(report_t, date_format_) { - on(none, "%y-%b-%d"); - }); + OPTION(report_t, date_format_); + OPTION(report_t, datetime_format_); OPTION_(report_t, depth_, DO_(scope) { interactive_t args(scope, "sl"); @@ -633,9 +632,9 @@ public: OPTION__(report_t, print_format_, CTOR(report_t, print_format_) { on(none, - "%(format_date(xact.date, \"%Y/%m/%d\"))" + "%(xact.date)" "%(!effective & xact.effective_date ?" - " \"=\" + format_date(xact.effective_date, \"%Y/%m/%d\") : \"\")" + " \"=\" + xact.effective_date : \"\")" "%(xact.cleared ? \" *\" : (xact.pending ? \" !\" : \"\"))" "%(code ? \" (\" + code + \")\" :" " \"\") %(payee)%(xact.comment)\n" @@ -673,7 +672,8 @@ public: OPTION__(report_t, register_format_, CTOR(report_t, register_format_) { on(none, - "%(ansify_if(justify(date, date_width), green if color & date > today))" + "%(ansify_if(justify(format_date(date), date_width), green " + " if color & date > today))" " %(ansify_if(justify(truncated(payee, payee_width), payee_width), " " bold if color & !cleared))" " %(ansify_if(justify(truncated(account, account_width, abbrev_len), " |