Here is an example:

Issue #1 - the sales qty should update to 40 not the original 44. I believe this quantity is updated during the invoicing process of the order. I verified that simply reserving the amount does not update the qty.
Issue #2 and the issue I am asking about, I need the Swell allowance to be calculated on the total line/order value AFTER ALL OTHER ADJUSTMENTS ARE APPLIED.
How can this be accomplished in an automated way?