Conversation
feversocial
left a comment
There was a problem hiding this comment.
Please also update instructions and readme accordingly, explaining in couple of sentences how current logic of refund looks like.
| { | ||
| public const string PAYMENT_STATUS_NEW = 'new'; | ||
|
|
||
| public const string PAYMENT_STATUS_AUTHORIZATION_PENDING = 'authorization_pending'; |
There was a problem hiding this comment.
I see you're removing a lot of constatnts.. is this just a cleanup, they were not used?
There was a problem hiding this comment.
Yes, these were not used. It's a clean up.
| <event>refund</event> | ||
| </transition> | ||
|
|
||
| <transition happy="true" condition="PaymentTemplate/IsRefunded"> |
There was a problem hiding this comment.
I would not do that as OOTB suggestion; That process means that condition checks every time if refund happened or not, which is a lot of useless calls. Instead, I would assume that transition to the refund process is triggered manually. Happy case does not go through the refund. It goes from captured to closed automatically after 30 days; In between, manual transition to refund is possible
There was a problem hiding this comment.
I do not quite get why this will be checked every minute. It'll only happen if someone manually clicked the REFUND button first, so this one is waiting for a callback from that trigger. In most cases these should be fast.
Even if not fast this check is supposed to be checking the notification in the DB, not actually pinging the PSP.
Or do you have an issue with the "happy" attribute? It makes sense to remove that as refund is not a happy process to a ecom :)
Added OMS handling for refunds.