IO-747 CCC Scroll to Job in Table on create

This commit is contained in:
Patrick Fic
2021-03-08 17:05:06 -08:00
parent 0930702da8
commit 43c771b4f6
3 changed files with 34 additions and 9 deletions

View File

@@ -173,9 +173,9 @@ function CalculateRatesTotals(ratesList, shoprates) {
let subtotal = Dinero({ amount: 0 });
let rates_subtotal = Dinero({ amount: 0 });
for (const property in ret) {
ret[property].total = Dinero({ amount: ret[property].rate * 100 }).multiply(
ret[property].hours
);
ret[property].total = Dinero({
amount: Math.round((ret[property].rate || 0) * 100),
}).multiply(ret[property].hours);
subtotal = subtotal.add(ret[property].total);
if (property !== "mapa" && property !== "mash")
rates_subtotal = rates_subtotal.add(ret[property].total);
@@ -336,7 +336,6 @@ function CalculateTaxesTotals(job, otherTotals) {
0) * 100
)
);
console.log("A", additionalItemsTax.toJSON());
} else {
statePartsTax = statePartsTax.add(
Dinero({ amount: Math.round((val.act_price || 0) * 100) })
@@ -348,7 +347,6 @@ function CalculateTaxesTotals(job, otherTotals) {
0) * 100
)
);
console.log("S", statePartsTax.toJSON());
}
});