debugging settlements and working on getting that to affect the totals. Not quite right but almost