protected function ReplicationListBuilder::generateMessageRenderArray in Deploy - Content Staging 8
Generate a message render array with the given text.
Parameters
string $type: The type of message: status, warning, or error.
string $message: The message to create with.
Return value
array The render array for a status message.
See also
\Drupal\Core\Render\Element\StatusMessages
1 call to ReplicationListBuilder::generateMessageRenderArray()
- ReplicationListBuilder::render in src/
ReplicationListBuilder.php - Builds the entity listing as renderable array for table.html.twig.
File
- src/
ReplicationListBuilder.php, line 168
Class
- ReplicationListBuilder
- Defines a class to build a listing of Replication entities.
Namespace
Drupal\deployCode
protected function generateMessageRenderArray($type, $message) {
return [
'#theme' => 'status_messages',
'#message_list' => [
$type => [
Markup::create($message),
],
],
];
}