<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — Re:Tax (GST) payments or invoice basis (Alastair Robertson) 04/22/2013]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=10742</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=10742&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Re:Tax (GST) payments or invoice basis (Alastair Robertson) 04/22/2013.]]></description>
		<lastBuildDate>Mon, 12 Oct 2026 10:09:05 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re:Tax (GST) payments or invoice basis (Alastair Robertson) 04/22/2013]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=43886#p43886</link>
			<description><![CDATA[<p>Firstly, thank you Alastair for the module. This is not a new post but for some reason I was unable to reply to the post above. I may have downloaded the module from the wrong place, but on a payments-basis GST return, the input tax on a paid supplier invoice was added to the output tax instead of being deducted from it.</p><p>For example, output GST of 4,434.79 and input GST of 375.52 was reported as a net payable of 4,810.31. The correct net payable is 4,059.27.</p><p>FrontAccounting stores a supplier payment with a negative ov_amount. The input-tax part of the report joined supp_trans on the payment (trans_type_from) and divided by that payment total. Dividing by a negative amount flipped the sign of the input GST, so collectible + payable added the input tax instead of subtracting it.</p><p>The fix is to divide by the supplier invoice total (trans_type_to). The invoice amount is positive, the existing -1 then makes the input GST a deduction, and the net payable is correct.</p><p>File: includes/tax_cash_db.inc</p><p>In tax_cash_sql(), change the supplier-allocation block from:</p><p>ttd.net_amount*sa.amt/round(ov_amount+ov_gst+ov_discount,6)*ex_rate net_input,<br />-1*ttd.amount*sa.amt/round(ov_amount+ov_gst+ov_discount,6)*ex_rate collectible,<br />...<br />INNER JOIN &quot;.TB_PREF.&quot;supp_trans st<br />&nbsp; &nbsp; ON st.type = sa.trans_type_from<br />&nbsp; &nbsp; AND st.trans_no = sa.trans_no_from</p><p>to:</p><p>ttd.net_amount*sa.amt/round(inv.ov_amount+inv.ov_gst+inv.ov_discount,6)*ex_rate net_input,<br />-1*ttd.amount*sa.amt/round(inv.ov_amount+inv.ov_gst+inv.ov_discount,6)*ex_rate collectible,<br />...<br />INNER JOIN &quot;.TB_PREF.&quot;supp_trans inv<br />&nbsp; &nbsp; ON inv.type = sa.trans_type_to<br />&nbsp; &nbsp; AND inv.trans_no = sa.trans_no_to</p><p>After the change, the input line shows as a negative amount and the total payable is the output GST less the input GST. The same figure is used by the Tax Details (Cash Basis) report.</p>]]></description>
			<author><![CDATA[null@example.com (DiggerNZ)]]></author>
			<pubDate>Mon, 12 Oct 2026 10:09:05 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=43886#p43886</guid>
		</item>
	</channel>
</rss>
