Problems with commerce-order-receipt.html.twig

Created on 23 June 2024, 7 days ago

Describe your bug or feature request.

First problem: the customer name is not available.
there was a way to do it with

function my_theme_preprocess_commerce_order_receipt(&$variables) {
  $givenName = $variables['billing_information']['#profile']->get('address')[0]->given_name;
  $variables['given_name'] = $givenName;
  $familyName = $variables['billing_information']['#profile']->get('address')[0]->family_name;
  $variables['family_name'] = $familyName;
}

But that is not working anymore. Even

function my_theme_preprocess_commerce_order_receipt(&$variables) {
  $variables['test'] = "test";
}

does not work.

Second problem: the template file in the theme folder is not used.

Another problem with eMail is, that there is no possibility for attachements.

✨ Feature request
Status

Active

Version

2.38

Component

Order

Created by

πŸ‡©πŸ‡ͺGermany Umac_de

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024