SFS 'picker list' change treatment events cause incorrect billing

Description

When Smart Flow Sheet generates treatment events for Picker List changes, it adds the new treatment prior to removing the old one. This means that the Customer Pharmacy Order temporarily has two line items.
However the removal doesn't have an inventoryId, so it is not clear which of the line items should be removed.

Both treatment events are included in a single treatments.records_entered object, so the workaround is to re-order these so that removals are processed first.

Environment

None

Status

Assignee

Tim Anderson

Reporter

Tim Anderson

Labels

None

Components

Fix versions

Affects versions

Priority

Minor
Configure