Bug 5522,5523,5524: Journal Entry Affecting in both sales and purchase med flera...
[fa-stable.git] / reporting / rep709.php
index 36984ff290ef43903e3c1e963ec24f59b0e84c37..bd807a6973fcd7b8ff915da694587a72a09b0925 100644 (file)
@@ -133,7 +133,8 @@ function print_tax_report()
 
        while ($trans=db_fetch($transactions))
        {
-               if (in_array($trans['trans_type'], array(ST_CUSTCREDIT,ST_SUPPINVOICE,ST_JOURNAL))) {
+               if (in_array($trans['trans_type'], array(ST_CUSTCREDIT,ST_SUPPINVOICE)) ||
+                       ($trans['trans_type'] == ST_JOURNAL && $trans['reg_type'] == TR_INPUT)) {
                        $trans['net_amount'] *= -1;
                        $trans['amount'] *= -1;
                }