Merged in hotfix/2021-05-31 (pull request #84)
Emergency fix #2 for GST Registrant.
This commit is contained in:
@@ -425,12 +425,18 @@ function CalculateTaxesTotals(job, otherTotals) {
|
|||||||
.add(ret.state_tax)
|
.add(ret.state_tax)
|
||||||
.add(ret.local_tax);
|
.add(ret.local_tax);
|
||||||
|
|
||||||
|
console.log(
|
||||||
|
"Checking GST",
|
||||||
|
job.ca_customer_gst !== 0,
|
||||||
|
job.ca_customer_gst !== null
|
||||||
|
);
|
||||||
|
|
||||||
ret.custPayable = {
|
ret.custPayable = {
|
||||||
deductible: Dinero({ amount: (job.ded_amt || 0) * 100 }) || 0,
|
deductible: Dinero({ amount: (job.ded_amt || 0) * 100 }) || 0,
|
||||||
federal_tax: job.ca_gst_registrant
|
federal_tax: job.ca_gst_registrant
|
||||||
? job.ca_customer_gst !== 0 || job.ca_customer_gst !== null
|
? job.ca_customer_gst === 0 || job.ca_customer_gst === null
|
||||||
? Dinero({ amount: Math.round(job.ca_customer_gst * 100) })
|
? ret.federal_tax
|
||||||
: ret.federal_tax
|
: Dinero({ amount: Math.round(job.ca_customer_gst * 100) })
|
||||||
: Dinero(),
|
: Dinero(),
|
||||||
other_customer_amount: Dinero({
|
other_customer_amount: Dinero({
|
||||||
amount: (job.other_amount_payable || 0) * 100,
|
amount: (job.other_amount_payable || 0) * 100,
|
||||||
|
|||||||
Reference in New Issue
Block a user