3.0.0 - 26th Sept. 2024
TYPO3 13 compatibility + Recipient group refactoring
- Add more possibilities to manipulate recipient groups using query restrictions on tables or extbase model based recipient sources
- Enhanced csv based recipient groups
- Add feature to reduce the list of recipients of a mailing by choosing one or more other recipient groups
- Improved bounce mails handing (needs IMAP account now!)
New features
-
Add RecipientsRestrictionEvent to manipulate querys of extbase model recipient sources. This way it is now possible to e.g. filter recipient lists coming from extbase.
See here how to use:
- https://gitlab.com/mediaessenz/additional-mail-recipients/-/blob/main/Configuration/Site/RecipientSources.yaml (recipientSources:male_tt_address)
- https://gitlab.com/mediaessenz/additional-mail-recipients/-/blob/main/Classes/EventListener/AddressModelRestriction.php
- https://gitlab.com/mediaessenz/additional-mail-recipients/-/blob/main/Configuration/Services.yaml
-
Add possibility to define one or more query restrictions to manipulate table recipient sources. This way it is now possible to e.g. filter recipient lists coming from tables.
See here how to use:
- To make it possible to use a table more than once, a new recipient source confiiguration property
table
was added. If not set, the identifier is used as table name instead. - The mail queue is now pausable. This opens the possibility to pause a running delivery to e.g. give another delivery priority.
-
A new recipient group type "CSV" was added with additional configuration settings:
- Type "Plain CSV" and "CSV from file"
- Field separator
- Field enclosure
- First line contains field names, which makes it possible to use every field defined in the extension settings "defaultRecipientFields" or "additionalRecipientFields" as marker
- CSV file as source (file must be UTF-8 encoded!)
- The bounce mail handling was enhanced to handle recipients from csv and plain lists as well. After deactivate bounced recipients inside the report module, the affected emails will be changed inside there source (recipient group record or csv file) like so: invalid-email@domain.com -> !invalid!--invalid-email[at]domain.com. In this way, any other data for this user is retained. However, it will no longer be used as a recipient due to the invalid email.
- The last step of the Mail Wizard has been expanded to include a new “Exclude recipient groups” selection, which allows to define one or more recipient groups that are to be excluded from a mailing. This makes it possible, for example, to exclude a few people from a larger list in order to prevent them from receiving a specific mailing. This list could be a plain list with just email addresses.
Breaking changes
-
Recipient Source Configurations now uses the DTO
MEDIAESSENZ\
.Domain\ Model\ Dto\ Recipient Source Configuration DTO Previously the getRecipientSourceConfiguration method of the following events returns an array:
- ManipulateMarkersEvent
- ManipulateRecipientEvent
- DeactivateRecipientEvent
Please adjust your event listeners to use e.g.
$recipients
instead ofSource Configuration->table $recipients
. There is also aSource Configuration ['table'] custom
property available to transfer custom yaml config into event listeners.mail: recipientSources: myCustomDataSource: custom: foo: bar
Copied!This will be available as
$recipients
in an event listener.Source Configuration->custom ['foo'] - Plain Lists and CSV recipient groups are now different recipient group types. A migration wizard to convert from the old to new format comes with this version. Attention: Before using the migration wizard please do a database compare, but do not rename or remove the field "csv" in the first step! After the new fields "csv_type", "csv_data", "csv_separator" and "csv_file" have been generated, goto admin tools > upgrade and click on upgrade wizard. Here start the wizard with the title: "EXT:mail: Migrate mail group type plain to plain or new group csv, depending on csv type.". After this, you can safely delete the field "csv" from the tx_mail_domain_model_group database table.
-
Mail records now have a status field, which can hold (currently) 5 different states:
- 0 = DRAFT
- 1 = SCHEDULED
- 2 = SENDING
- 3 = PAUSED
- 4 = ABORTED
- 5 = SENT
There is an update wizard to convert existing mail records. Please do not delete the mail database field "sent" or rename it to "zzz_deleted_sent" before running it once!
As a side effect, the backend module of the queue now only shows scheduled mails that have not yet been sent.
- For a better bounce mail handling MAIL now uses ddeboer/imap instead of tedivm/fetch. Since ddeboer/imap only can handle IMAP accounts, the possibility to use a POP3 account for collecting bounce mails is dropped. As the mail server type parameter in the bounce mail command is therefore obsolete, it is also deleted. The parameter "count", to set the number of bounce mail to be processed per run, was dropped as well, since it should not be a critical thing, to handle all found bounce mail in one run. Due to this changes, all scheduler task using this command may be corrupt after updating to MAIL 3.0. In dought just recreate them.