[FIX] account: pdf report of general ledger was including the first day of range in the initial balance. PR #11316

This commit is contained in:
qdp-odoo
2016-04-18 09:51:25 +02:00
parent f4d79a2b8e
commit 9aa8a212d3
@@ -31,7 +31,7 @@ class ReportGeneralLedger(models.AbstractModel):
# Prepare initial sql query and Get the initial move lines
if init_balance:
init_tables, init_where_clause, init_where_params = MoveLine.with_context(date_to=self.env.context.get('date_from'), date_from=False)._query_get()
init_tables, init_where_clause, init_where_params = MoveLine.with_context(date_from=self.env.context.get('date_from'), date_to=False, initial_bal=True)._query_get()
init_wheres = [""]
if init_where_clause.strip():
init_wheres.append(init_where_clause.strip())