fix to amount printing
This commit is contained in:
parent
42298cefd5
commit
bb044f8820
3 changed files with 13 additions and 6 deletions
|
|
@ -525,7 +525,9 @@ std::ostream& operator<<(std::ostream& out, const amount_t& amt)
|
|||
|
||||
bool printed = false;
|
||||
|
||||
for (strings_list::iterator i = strs.begin(); i != strs.end(); i++) {
|
||||
for (strings_list::reverse_iterator i = strs.rbegin();
|
||||
i != strs.rend();
|
||||
i++) {
|
||||
if (printed) {
|
||||
out << (amt.commodity->flags & COMMODITY_STYLE_EUROPEAN ? '.' : ',');
|
||||
out.width(3);
|
||||
|
|
|
|||
|
|
@ -327,10 +327,10 @@ bool format_account::disp_subaccounts_p(const account_t * account,
|
|||
for (accounts_map::const_iterator i = account->accounts.begin();
|
||||
i != account->accounts.end();
|
||||
i++) {
|
||||
// jww (2004-08-03): How do compute the right figure? It should a
|
||||
// value expression specified by the user, to say, "If this
|
||||
// expression is equivalent between a parent account and a lone
|
||||
// displayed child, then don't display the parent."
|
||||
// jww (2004-08-03): How to compute the right figure? It should
|
||||
// be a value expression specified by the user which says, "If
|
||||
// this expression is equivalent between a parent account and a
|
||||
// lone displayed child, don't display the parent."
|
||||
|
||||
if (! (*i).second->total || ! disp_pred((*i).second))
|
||||
continue;
|
||||
|
|
|
|||
7
main.cc
7
main.cc
|
|
@ -204,6 +204,11 @@ OPT_BEGIN(file, "f:", true) {
|
|||
use_cache = false;
|
||||
} OPT_END(file);
|
||||
|
||||
#if 0
|
||||
OPT_BEGIN(cache, ":") {
|
||||
} OPT_END(cache);
|
||||
#endif
|
||||
|
||||
OPT_BEGIN(output, "o:", false) {
|
||||
if (std::string(optarg) != "-")
|
||||
output_stream.reset(new std::ofstream(optarg));
|
||||
|
|
@ -448,7 +453,7 @@ int main(int argc, char * argv[], char * envp[])
|
|||
|
||||
TIMER_START(read_cache);
|
||||
|
||||
// jww (2004-08-13): use LEDGER_FILE
|
||||
// jww (2004-08-13): use LEDGER_FILE and LEDGER_CACHE
|
||||
use_cache = std::getenv("LEDGER") != NULL;
|
||||
|
||||
if (use_cache) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue