Improvements to email interface

Created on 15 October 2024, 6 months ago

Problem/Motivation

Improvements based on discussions of the the likely direction for Drupal Core mailer, and experience of using the current interfaces.

Proposed resolution

Instead of type/sub-type/entity_id have a single field tag, like symfony. The 3-way split isn't relevant to code building and sending emails rather it's mostly for Mailer Policy, which likely won't ever be in Core. So we just keep it within the mailer policy code. The value that was set as the entity can instead just be a normal parameter.
EmailInterface::setBodyEntity() is confusing, really it is just setting a variable by rendering an entity. Hence rename to setEntityVariable().
New convenience function setEntityParam() which automatically uses the entity type as the key, as per the recommendation.

Remaining tasks

User interface changes

API changes

Data model changes

📌 Task
Status

Active

Version

2.0

Component

Code

Created by

🇬🇧United Kingdom adamps

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

Comments & Activities

Production build 0.71.5 2024