1

I followed Drupal Commerce: Print order? solution:

Through Rules you can achieve this by creating a Rule within the Rules module:

First step create a custom rule at /admin/config/workflow/rules/reaction/add Select the React on event: "Completing the checkout process" Add a new Action: "Send mail" Once you add the email addresses from/to, than add the replacement fields in the body text of the email. I suggest: [commerce-order:order-number], [commerce-order:type], [commerce-order:commerce-line-items]. But you can figure that part out. Save your Rule.

I receive the email but I do not have a proper list of ordered products, instead I have numbers. One per article but the change on each order even if the articles are the same.

How can I have a proper order listing in the email?

2

You will want to use the Commerce Message module: https://www.drupal.org/project/commerce_message

This module provides a !order-summary token which embeds an order's line item summary. This token only works, however, if the Message bundle has the message_commerce_order field.

You can either programmatically add this to a new Message bundle. Or, the easy route, clone the default admin notification and adjust as needed!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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