diff options
| author | einhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46> | 2008-10-14 20:26:40 +0000 |
|---|---|---|
| committer | einhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46> | 2008-10-14 20:26:40 +0000 |
| commit | 13a94bbf789a9c9b41f052c4f230e9acf9fbc105 (patch) | |
| tree | aac3ef2eeeb3aee05b546e3d484d9d6ba172368a /LedgerSMB | |
| parent | 70917210d2437b36ae8faf21418f007b11819b7d (diff) | |
Correcting handling of blank inputs.
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@2370 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'LedgerSMB')
| -rw-r--r-- | LedgerSMB/RP.pm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/LedgerSMB/RP.pm b/LedgerSMB/RP.pm index dfff734f..816980de 100644 --- a/LedgerSMB/RP.pm +++ b/LedgerSMB/RP.pm @@ -1453,6 +1453,12 @@ sub trial_balance { my $datefrom = $dbh->quote($form->{fromdate}); my $dateto = $dbh->quote($form->{todate}); my $safe_project_id = $dbh->quote($project_id); + if ($datefrom eq "''") { + $datefrom = "NULL"; + } + if ($dateto eq "''") { + $dateto = "NULL"; + } $query = "SELECT c.id AS chart_id, c.accno, c.description, c.contra, c.category, SUM(CASE WHEN ac.transdate < $datefrom |
