Skip to content

order-email

Auto Added by WPeMatico

Magento2 | Change subject email of new order if condition is true

I created an observer that changes the email subject when I place a new order: This is the ChangeOrderEmailSubject.php file: <?php namespace SalesOrderCustObserver; use MagentoFrameworkEventObserverInterface; use MagentoFrameworkEventObserver; use MagentoSalesModelOrder; class ChangeOrderEmailSubject implements ObserverInterface { public function execute(Observer $observer) { /**… Read More »Magento2 | Change subject email of new order if condition is true

Magento2 Order email missing custom variable values for first time & when I send email from admin it shows values

Magento2 Order email missing custom variable values for first time & when I send email from admin it shows values Basically this custom variable values are the order attributes. I have used this email_order_set_template_vars_before event to set the order attribute… Read More »Magento2 Order email missing custom variable values for first time & when I send email from admin it shows values