noalyss-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Noalyss-commit] [noalyss] 153/323: FIX : PRINTJRN, ledger PDF


From: Dany De Bontridder
Subject: [Noalyss-commit] [noalyss] 153/323: FIX : PRINTJRN, ledger PDF
Date: Wed, 14 Mar 2018 17:38:41 -0400 (EDT)

sparkyx pushed a commit to branch master
in repository noalyss.

commit a1e0c9fcb29f195824638fa2866ccb8dfd84c77d
Author: Dany De Bontridder <address@hidden>
Date:   Thu Feb 8 22:19:07 2018 +0100

    FIX : PRINTJRN, ledger PDF
---
 include/class/acc_ledger.class.php | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/include/class/acc_ledger.class.php 
b/include/class/acc_ledger.class.php
index 8e5982b..43a16b0 100644
--- a/include/class/acc_ledger.class.php
+++ b/include/class/acc_ledger.class.php
@@ -45,6 +45,7 @@ require_once NOALYSS_INCLUDE.'/lib/sort_table.class.php';
 require_once NOALYSS_INCLUDE.'/database/jrn_def_sql.class.php';
 require_once NOALYSS_INCLUDE.'/class/acc_payment.class.php';
 require_once NOALYSS_INCLUDE.'/class/acc_ledger_history.class.php';
+//require_once NOALYSS_INCLUDE.'/class/print_ledger.class.php';
 require_once NOALYSS_INCLUDE.'/lib/http_input.class.php';
 
 /** \file
@@ -2634,6 +2635,11 @@ class Acc_Ledger extends jrn_def_sql
         if ( empty($pa_ledger) ) {
             $pa_ledger=[$this->id];
         }
+        // if $pa_ledger == 0, it means we need to show all ledgers
+        if ( $pa_ledger == [0] ) {
+            $pa_ledger=Print_Ledger::available_ledger($p_from);
+        }
+        
         $alh_generic=new Acc_Ledger_History_Generic($this->db, $pa_ledger, 
$p_from, $p_to, "A");
         $alh_generic->get_rowSimple($trunc,$p_limit,$p_offset);
         $data=$alh_generic->get_data();



reply via email to

[Prev in Thread] Current Thread [Next in Thread]