[Bug] Transaction Rollbacks - Reminder Rollbacks

I have just noticed (1.9 Snapshot) that when a patient has an outstanding reminder lets say for a vaccination.  When I bill a new Item that contains a reminder that is part of that reminder group (again lets say a vaccination) The existing reminder will be marked complete and a new reminder is created for the item (this occurs as soon as the item is created in the "in progress" invoice.  

If at a later stage I realize I billed for the wrong item - I meant to bill a different vaccination eg I billed for a 3 yearly c5 and I meant to bill a yearly BB.  The newly created reminders will be rolled back  BUT the reminder that were autocompleted when the new reminders were created will NOT be rolled back

This means that effectively the pet will no longer receive the reminder for the original vaccination.

This is a major issue as it means any flea or tick sales that are billed accidentally or a change of mind will remove potentially valuable reminders that the client will NEVER recieve.  

 

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Re: [Bug] Transaction Rollbacks - Reminder Rollbacks

Its not a bug, but a limitation of the the way reminders are implemented.

It is also occurs with demographic updates. E.g. if you charge a desexing product that sets the patient as being desexed, and then delete or reverse the charge, the patient is still flagged as being desexed

In the case of reminders, it would be possible to link completed reminders to the ones that marked them completed so that if the new reminder is subsequently deleted, the original reminder is re-instated. This might cause problems if the re-instated reminder is no longer applicable.

In the case of demographic updates, support could be added to undo them by specifying a different function (e.g. patient:setDesexed(false)).

Re: [Bug] Transaction Rollbacks - Reminder Rollbacks

I'll be honest and say that IMO the ability of a unfinalized transaction to remove future reminder is a bit a of deal breaker for me.   The potential for lost revenue ie really very high.  I cant imagine anyone else feeling any different , I wasnt initially concerned about demo updates but then I just realized that sometimes I have staff that might search a desex price using a unfinalised invoice and then I realized that its a real problem as well

 

 

Regards
 
Ben 
OpenVPMS Installer and Helper 
Ph: +61423044823 
Email: info[at]charltonit.com[dot]au

Re: [Bug] Transaction Rollbacks - Reminder Rollbacks

Both reminder completion and demographic updates only occur when you save the invoice, so adding an item to check its price is safe so long as you don't save. That said, price checking is best done using an estimate.

In terms of reinstating reminders, I'm not sure it can be done automatically. 

Consider:

  • reminder type 1 has group A
  • reminder type 2 has groups A, B
  • reminder type 3 has group A, and is used as a stopper reminder

If you charge:

  • product X which creates reminder 1 (reminder type 1); and then
  • product Y which creates reminder 2 (reminder type 2) - this completes reminder 1; and then
  • product Z which creates reminder 3 (reminder type 3) - this completes reminder 2; and then
  • delete the product Y

Reminder 1 shouldn't be re-instated as it would have been completed by reminder 3.

I think it would therefore need to prompt:

    Reminder Type 1 was completed when product X was invoiced. Do you wish to re-instate it?

The same would apply for demographic updates. E.g.:

Do you wish to revert the changes made by "Patient Deceased Demographic Update"?

 

Re: [Bug] Transaction Rollbacks - Reminder Rollbacks

A possible solution would be to generate the reminders during charging, but only mark matching reminders complete when the invoice is finalised. This would allow invoice items to be changed or removed without affecting existing reminders, up until the point the invoice is finalised. On finalisation, the new reminders mark existing matching reminders completed.

This might fall down if you tend to keep invoices open for long periods, or don't finalise an invoice before reminder generation is done; duplicate or incorrect reminders might get generated.

Re: [Bug] Transaction Rollbacks - Reminder Rollbacks

This could be worked around by introducing a new PENDING status for reminders. This would be used when reminders are created during invoicing. It would not be available when editing reminders. When the invoice is finalised, the associated reminders would be set to IN_PROGRESS, before marking existing matching reminders completed. Stopper reminders would be automatically marked COMPLETED.

Syndicate content