Manually revert a transaction when ticket is been reopened

I have a special way of adding Tip to a Ticket. When the Tip has been added and the ticket is been closed a Tip Transaction must be added.

I have created a custom action that adds a new Tip Transaction for the Tip as described above. When the Ticket is closed 3 Transactions appear in the corresponding Transaction Document. When the ticket is reopened only one transaction is been removed, the Tip transaction remains. So, if I close the ticket now it will regenerate a Tip transaction and thus double the tip amount in the Tips Account.

Why is the Tip Transaction not been removed when the ticket is been reopened?
Should I create another “inverted” tip transaction for when the ticket is reopened?

It depends how you are adding the Tip Transaction.

If it is a Calculation, I think it will be removed properly, but not sure.

I came across this same issue when using Rounding Calculations applied via Processors IIRC, and I needed to set up an Action to toggle all Rounding Calculations using zero as the Amount after the Ticket was re-opened.

Action - named “Round Remove”, but since it has variable parameters for everything, it is really just a Generic Update Ticket Calculation Action:

The Rule fires that Action 4 times to hit all the Rounding Calculations that could be on the Ticket: