Merged changes from stable branch up to 2.3.23.
[fa-stable.git] / reporting / rep201.php
index 1d25b8af6754c5aeb1089b014659ccab8d1898ca..d06adb53a1655f8121af15ca1c43c5dfc5692c17 100644 (file)
@@ -174,9 +174,11 @@ function print_supplier_balances()
                        $grandtotal[$i] += $init[$i];
                }
                $rep->NewLine(1, 2);
-               if (db_num_rows($res)==0) continue;
-
                $rep->Line($rep->row + 4);
+               if (db_num_rows($res)==0) {
+                       $rep->NewLine(1, 2);
+                       continue;
+               }       
                while ($trans=db_fetch($res))
                {
                        if ($no_zeros && floatcmp(abs($trans['TotalAmount']), $trans['Allocated']) == 0) continue;
@@ -240,4 +242,3 @@ function print_supplier_balances()
     $rep->End();
 }
 
-?>