-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Issue] Fix offline invoice capture (404) #39298
Comments
Hi @engcom-Bravo. Thank you for working on this issue.
|
Hi @nige-one, Thanks for your reporting and collaboration. We have tried to reproduce the issue in Latest 2.4-develop instance and we are not able to proceed further.Could you please elaborate the steps regarding Capture the invoice in Magento Backend. Thanks. |
Hi @engcom-Bravo thanks for checking. I missed that Magento's default offline payment methods do not allow to capture. We implemented a simple custom offline payment method with:
This allows our merchant to track payments for manually managed payments (bank transfer). I see that Nonetheless, since the rendered 'Capture' button in the backend will always be a GET request:
and
the mentioned commit 3e63705#diff-f55a86b611d11bb9a801c4b16ba9ac4b17dab4c325d252b86d5d3a8b8275c291 will always break the button functionality. One could argue to implement a "Paid" button for a custom offline payment method instead of the "Capture" one, but this will still render the "Capture" button useless anyway. So, from my perspective this is a breaking change. |
Hi @engcom-Hotel. Thank you for working on this issue.
|
Hello @nige-one, Thanks for the detailed explanation! We agree your point, hence confirming this issue after looking into the code changes. Thanks |
✅ Jira issue https://jira.corp.adobe.com/browse/AC-13336 is successfully created for this GitHub issue. |
✅ Confirmed by @engcom-Hotel. Thank you for verifying the issue. |
This issue is automatically created based on existing pull request: #39297: Fix offline invoice capture (404)
Description (*)
It's not possible to capture offline payment method invoices via the backend ('Capture' button). Trying it will lead to a 404.
Related Pull Requests
The issue comes from 3e63705#diff-f55a86b611d11bb9a801c4b16ba9ac4b17dab4c325d252b86d5d3a8b8275c291
The class has been changed to be implementing
HttpPostActionInterface
. Clicking the 'Capture' button will send a GET request. Magento's request validator\Magento\Framework\App\Request\HttpMethodValidator
will throw an exception leading to a 404 because it expects a POST request.Manual testing scenarios (*)
The text was updated successfully, but these errors were encountered: