mollie / magento2

Mollie Payments for Magento 2
https://www.mollie.com
Other
98 stars 50 forks source link

Second chance email is not send for Failed payment status #635

Closed roxanadicomaria closed 1 year ago

roxanadicomaria commented 1 year ago

Describe the bug When the payment status is "Failed" then the order is canceled by the Mollie\Payment\Model\Client\Payments\Processors\FailedStatusProcessor and the second chance email is no longer sent. Is there a way to fix this?

Used versions

To Reproduce Steps to reproduce the behavior:

  1. Place an order with Klarna, for example, and in test mode, select Failed
  2. Order is canceled.
  3. You are redirected back to cart, and if you don't do anything the second chance email is not sent

Expected behavior Second chance email should be sent after the set amount of time (i.e. 1h).

Actual behavior The second chance email cron runs, but because the order is canceled this will be removed from pending queue.

Frank-Magmodules commented 1 year ago

Hello @roxanadicomaria, we couldn't find any existing issues related to the matter you mentioned. Could you please share your staging or environment details with us directly by filling out this support form? This will allow us to investigate the issue more closely together.

roxanadicomaria commented 1 year ago

Hi,

Thank you for contacting us. The main problem was basically that one of our clients requested that for FAILED orders, the email shouldn't be sent, only for orders that were indeed cancelled on purpose. And in both cases, the state and the status where set to "canceled" https://prnt.sc/1xNOaSBkaglX And my initial question would have been to ask you if there is a way to alter the state and make a difference between this 2 cases, but meanwhile, I followed the flow and I've noticed that I can make use of "sales_order_payment" table and it's column additional_information and inside it, there is "payment_status":"failed"," for the failed orders, so I was able to make use of this and obtain the customer request. So thank you for your time, we can close the ticket!