diff --git a/client/src/components/job-bills-total/job-bills-total.component.jsx b/client/src/components/job-bills-total/job-bills-total.component.jsx index f4dbb80ea..8f8ba31e6 100644 --- a/client/src/components/job-bills-total/job-bills-total.component.jsx +++ b/client/src/components/job-bills-total/job-bills-total.component.jsx @@ -64,9 +64,9 @@ export default function JobBillsTotalComponent({ }) ); - const totalPartsSublet = Dinero(totals.parts.parts.total) - .add(Dinero(totals.parts.sublets.total)) - .add(Dinero(totals.additional.additionalCosts)); + const totalPartsSublet = Dinero(totals.parts.parts.total).add( + Dinero(totals.parts.sublets.total) + ); const discrepancy = totalPartsSublet.subtract(billTotals); diff --git a/client/src/components/job-reconciliation-modal/job-reconciliation-modal.component.jsx b/client/src/components/job-reconciliation-modal/job-reconciliation-modal.component.jsx index 39da47462..f817a4e73 100644 --- a/client/src/components/job-reconciliation-modal/job-reconciliation-modal.component.jsx +++ b/client/src/components/job-reconciliation-modal/job-reconciliation-modal.component.jsx @@ -18,8 +18,7 @@ export default function JobReconciliationModalComponent({ job, bills }) { .flat() || []; const jobLineData = job.joblines.filter( - (j) => - (j.part_type !== null && j.part_type !== "PAE") || IsAdditionalCost(j) + (j) => j.part_type !== null && j.part_type !== "PAE" ); return ( @@ -51,20 +50,3 @@ export default function JobReconciliationModalComponent({ job, bills }) { ); } - -function IsAdditionalCost(jobLine) { - //May be able to use db_ref here to help. - //936012 is Haz Waste Dispoal - //936008 is Paint/Materials - //936007 is Shop/Materials - - //Remove paint and shop mat lines. They're calculated under rates. - const isPaintOrShopMat = - jobLine.db_ref === "936008" || jobLine.db_ref === "936007"; - - return ( - (jobLine.lbr_op === "OP13" || //Added to resolve manual job lines coming into other totals because they have no reference. - (jobLine.db_ref && jobLine.db_ref.startsWith("9360"))) && - !isPaintOrShopMat - ); -}