MODINVOICE-50 we implemented calculation of the invoiceLine totals. These currently happen "on the fly", so the totals are never persisted. This works great if you're using GET by ID to retrieve invoiceLines, but it means that the totals are not present in search results.
Having these totals appear in the invoiceLine search resutls is apparently needed, so we need to change this behavior.
- Continue to calculate the totals upon creation/update, only now this information needs to be persisted.
- Upon GET by ID, calculate the totals and if different from what was retrieved, write it back to storage.
- adjustmentTotal, and total appear in the invoiceLines retrieved via GET by Query and GET by ID.
- Unit tests are updated
- API tests are updated
- Update sample data as needed (may or may not be)
NOTE: It may make sense to do this before implementing prorated adjustments (