Join GitHub today
Theme templates overrides don't work in environment emulation cross-area #10402
The theme templates overrides are not resolved correctly if we're in an environment emulation cross-area (e.g.: we're in adminhtml emulating frontend).
My particular case has been this: I have a custom template overriding the payment method info template, I login in the Magento admin, find an order, click "Send email". The email won't have the overridden template.
To render the payment method info block Magento emulates the order's store in the frontend area (https://github.com/magento/magento2/blob/develop/app/code/Magento/Payment/Helper/Data.php#L208) and then calls
The code of this method normally works because if we're not in an environment emulation cross-area, the execution will not fall into that
I'm going to submit a pull request with what I believe is a possible solution.
Steps to reproduce
Issue: Format is valid
Sep 5, 2017
This ticket has been marked as
Thank you for collaboration.
@alessandroniciforo, thank you for your report.
Unfortunately, we are archiving this ticket now as it did not get much attention from both Magento Community and Core developers for an extended period. This is done in an effort to create a quality, community-driven backlog which will allow us to allocate the required attention more easily.
You may learn more about this initiative following this link.
Please feel free to comment or reopen the ticket if you think it should be reviewed once more. Thank you for collaboration.
This issue should be re-opened as it is quite a fundamental flaw. It makes it impossible to properly override templates for transactional emails which is pretty serious.