Corrected double problem in period reports
xact_t::add_to_value, in cases where the xact had a "compound" total, was adding transaction values to the running total twice.
This commit is contained in:
parent
94aa8e5a91
commit
5fc1f9dce9
1 changed files with 2 additions and 6 deletions
|
|
@ -316,13 +316,9 @@ void xact_t::add_to_value(value_t& value, expr_t& expr)
|
|||
if (xdata_ && xdata_->has_flags(XACT_EXT_COMPOUND)) {
|
||||
add_or_set_value(value, xdata_->value);
|
||||
}
|
||||
|
||||
if (! xdata_ || ! xdata_->has_flags(XACT_EXT_NO_TOTAL)) {
|
||||
else if (! xdata_ || ! xdata_->has_flags(XACT_EXT_NO_TOTAL)) {
|
||||
bind_scope_t bound_scope(*expr.get_context(), *this);
|
||||
if (value.is_null())
|
||||
value = amount_t(0L);
|
||||
|
||||
value += expr.calc(bound_scope);
|
||||
add_or_set_value(value, expr.calc(bound_scope));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue