1

In Magento EE we have "Automated Email Reminder Rules" and standard template. I need add to template - abandonment cart items, But when magento send email (in app/code/core/Enterprise/Reminder/Model/Rule.php::sendReminderEmails (145 line)), for template set variable: $templateVars = array( 'store' => $store, 'coupon' => $coupon, 'customer' => $customer, 'promotion_name' => $storeData['label'], 'promotion_description' => $storeData['description'] ); If i want add cart items i need rewrite this class and add to template variable cart entity?

Maybe someone will offer another solution?

1 Answer 1

1

I think that you could create a block that render the items in the shopping cart and call it in your template. Here @David Manners explain how to do something like that

In you email add something like the following.

{{block type='core/template' area='frontend' template='email/template.phtml' items=$items}}

Then in your template add the following.

<?php foreach ($this->getItems() as $_item): ?>
     <p><?php echo $_item['name'] ?></p> <?php endforeach; ?> 

For more information I followed this blog

You can pass the customer as parameter and then in the block search for the shopping cart.

1
  • How can we add the products list in abandoned cart email templates in magento EE 2.3.x ? Commented Sep 2, 2020 at 3:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.