IO-2793 State Tax to QBO refactor
Signed-off-by: Allan Carr <allan.carr@thinkimex.com>
This commit is contained in:
@@ -72,15 +72,22 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state:
|
state:
|
||||||
!jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0
|
jobline.tax_part === false
|
||||||
? false
|
? false
|
||||||
: jobline.db_ref === "900511" ||
|
: jobline.part_type.toUpperCase() === "PAS" || jobline.part_type.toUpperCase() === "PASL"
|
||||||
jobline.db_ref === "900510" ||
|
? jobs_by_pk.tax_sub_rt === 0
|
||||||
(jobline.mod_lb_hrs === 0 && //Extending IO-1375 as a part of IO-2023
|
? false
|
||||||
jobline.act_price > 0 &&
|
: true
|
||||||
jobline.lbr_op === "OP14")
|
: jobs_by_pk.parts_tax_rates[`${jobline.part_type.toUpperCase()}`].prt_tax_in === false ||
|
||||||
? true
|
jobs_by_pk.parts_tax_rates[`${jobline.part_type.toUpperCase()}`].prt_tax_rt === 0
|
||||||
: jobline.tax_part
|
? false
|
||||||
|
: jobline.db_ref === "900511" ||
|
||||||
|
jobline.db_ref === "900510" ||
|
||||||
|
(jobline.mod_lb_hrs === 0 && //Extending IO-1375 as a part of IO-2023
|
||||||
|
jobline.act_price > 0 &&
|
||||||
|
jobline.lbr_op === "OP14")
|
||||||
|
? true
|
||||||
|
: jobline.tax_part
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -156,7 +163,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.tax_lbr_rt === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -224,7 +231,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.tax_paint_mat_rt === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -293,7 +300,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.tax_shop_mat_rt === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -379,7 +386,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.tax_tow_rt === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -439,7 +446,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.tax_str_rt === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -499,7 +506,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: InstanceManager({ imex: true, rome: false }),
|
federal: InstanceManager({ imex: true, rome: false }),
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.state_tax_rate === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
@@ -670,7 +677,7 @@ exports.default = function ({ bodyshop, jobs_by_pk, qbo = false, items, taxCodes
|
|||||||
{
|
{
|
||||||
local: false,
|
local: false,
|
||||||
federal: process.env.COUNTRY === "USA" ? false : true,
|
federal: process.env.COUNTRY === "USA" ? false : true,
|
||||||
state: !jobs_by_pk.state_tax_rate || jobs_by_pk.state_tax_rate === 0 ? false : true
|
state: jobs_by_pk.state_tax_rate === 0 ? false : true
|
||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -206,8 +206,13 @@ query QUERY_JOBS_FOR_RECEIVABLES_EXPORT($ids: [uuid!]!) {
|
|||||||
adjustment_bottom_line
|
adjustment_bottom_line
|
||||||
state_tax_rate
|
state_tax_rate
|
||||||
qb_multiple_payers
|
qb_multiple_payers
|
||||||
|
parts_tax_rates
|
||||||
tax_paint_mat_rt
|
tax_paint_mat_rt
|
||||||
tax_lbr_rt
|
tax_lbr_rt
|
||||||
|
tax_shop_mat_rt
|
||||||
|
tax_sub_rt
|
||||||
|
tax_tow_rt
|
||||||
|
tax_str_rt
|
||||||
owner {
|
owner {
|
||||||
accountingid
|
accountingid
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user