public static function Message::queryByTemplate in Message 8
Run a EFQ over messages from a given template.
Parameters
string $template: The message template.
Return value
array Array of message IDs.
Overrides MessageInterface::queryByTemplate
2 calls to Message::queryByTemplate()
- MessageCron::testPurge in tests/
src/ Functional/ MessageCron.php - Testing the deletion of messages in cron according to settings.
- MessageCron::testPurgeGlobalSettings in tests/
src/ Functional/ MessageCron.php - Test global purge settings and overriding them.
File
- src/
Entity/ Message.php, line 370
Class
- Message
- Defines the Message entity class.
Namespace
Drupal\message\EntityCode
public static function queryByTemplate($template) {
return \Drupal::entityQuery('message')
->condition('template', $template)
->execute();
}