summaryrefslogtreecommitdiff
path: root/LedgerSMB
diff options
context:
space:
mode:
Diffstat (limited to 'LedgerSMB')
-rw-r--r--LedgerSMB/RP.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/LedgerSMB/RP.pm b/LedgerSMB/RP.pm
index 816980de..99dbf1ce 100644
--- a/LedgerSMB/RP.pm
+++ b/LedgerSMB/RP.pm
@@ -1487,7 +1487,7 @@ sub trial_balance {
select id, approved FROM ar) g
ON (g.id = ac.trans_id)
JOIN chart c ON (c.id = ac.chart_id)
- WHERE ac.transdate <= $dateto OR $dateto IS NULL
+ WHERE (ac.transdate <= $dateto OR $dateto IS NULL)
AND ac.approved AND g.approved
AND ($safe_project_id IS NULL
OR $safe_project_id = ac.project_id)