summaryrefslogtreecommitdiff
path: root/src/report.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-02-10 22:37:05 -0400
committerJohn Wiegley <johnw@newartisans.com>2009-02-10 22:37:05 -0400
commit44518bc64066e715c2664ff666a81b857a1b00f9 (patch)
tree64fdcc97128b1582e8378087f1f1154d2e3176e1 /src/report.cc
parentf605e107fcaf8f2f12ec927895eddd72dbe2ea5b (diff)
downloadledger-44518bc64066e715c2664ff666a81b857a1b00f9.tar.gz
ledger-44518bc64066e715c2664ff666a81b857a1b00f9.tar.bz2
ledger-44518bc64066e715c2664ff666a81b857a1b00f9.zip
Wired up the "entry" command from 2.x, though it still needs to be ported.
Diffstat (limited to 'src/report.cc')
-rw-r--r--src/report.cc19
1 files changed, 18 insertions, 1 deletions
diff --git a/src/report.cc b/src/report.cc
index 97d7ba0c..78d91fdf 100644
--- a/src/report.cc
+++ b/src/report.cc
@@ -521,7 +521,7 @@ expr_t::ptr_op_t report_t::lookup(const string& name)
(reporter<account_t, acct_handler_ptr, &report_t::accounts_report>
(new format_equity(*this, HANDLER(print_format_).str()), *this));
else if (is_eq(p, "entry"))
- return NULL; // jww (2009-02-07): NYI
+ return WRAP_FUNCTOR(entry_command);
else if (is_eq(p, "emacs"))
return NULL; // jww (2009-02-07): NYI
break;
@@ -631,4 +631,21 @@ expr_t::ptr_op_t report_t::lookup(const string& name)
return NULL;
}
+string join_args(call_scope_t& args)
+{
+ std::ostringstream buf;
+ bool first = true;
+
+ for (std::size_t i = 0; i < args.size(); i++) {
+ if (first) {
+ buf << args[i];
+ first = false;
+ } else {
+ buf << ' ' << args[i];
+ }
+ }
+
+ return buf.str();
+}
+
} // namespace ledger