Added mutation observer to sum totals

This commit is contained in:
2022-01-07 10:41:49 +10:00
parent fc4a5d8624
commit 198d609e62
2 changed files with 28 additions and 1 deletions

View File

@@ -191,7 +191,7 @@ Array.prototype.where = function<x>(this: x[], property: string, value: any) {
return this.filter( item => (item as any)[property] === value)[0] || null
}
const money = (amount: number) => currency(amount, {fromCents: true})
const money = (amount: number, fromCents=true) => currency(amount, {fromCents: fromCents})
const moneyFromString = (amount: string) => currency(amount)
//Id generator.