Customise License Expiry Email Headers

Created on 17 June 2021, over 3 years ago
Updated 5 September 2024, 3 months ago

The body of the Commerce License Expiry message can be customised by altering a copy of the template commerce-license-expire.html.twig in a custom theme.

Is there a simple way to customise the email subject? Is the 'subject' value themeable, or does the plugin need to be extended, overridden or modified?

The email subject is built in commerce_license/src/Plugin/AdvancedQueue/JobType/LicenseExpireNotify.php public function process():

$params = [
      'headers' => [
        'Content-Type' => 'text/html; charset=UTF-8;',
        'Content-Transfer-Encoding' => '8Bit',
      ],
      'from' => $from,
      'subject' => $this->t('Your purchase of @license-label has now expired', [
        '@license-label' => $license->label(),
      ]),
      'license' => $license,
    ];

So I would need to alter the value for $params['subject'] value

💬 Support request
Status

Active

Version

2.0

Component

Code

Created by

🇬🇧United Kingdom robcarr Perthshire, Scotland

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024