reinstalled all contribs with composer
need to run : drush ev 'drupal_flush_all_caches();' drush cr and restart nginx and php-fpm before loading the website
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains composition.page.inc.
|
||||
*
|
||||
* Page callback for Composition entities.
|
||||
*/
|
||||
|
||||
use Drupal\Core\Render\Element;
|
||||
|
||||
/**
|
||||
* Prepares variables for Composition templates.
|
||||
*
|
||||
* Default template: composition.html.twig.
|
||||
*
|
||||
* @param array $variables
|
||||
* An associative array containing:
|
||||
* - elements: An associative array containing the user information and any
|
||||
* - attributes: HTML attributes for the containing element.
|
||||
*/
|
||||
function template_preprocess_composition(array &$variables) {
|
||||
// dpm($variables);
|
||||
// Fetch Composition Entity Object.
|
||||
$composition = $variables['elements']['#composition'];
|
||||
|
||||
// Helpful $content variable for templates.
|
||||
foreach (Element::children($variables['elements']) as $key) {
|
||||
$variables['content'][$key] = $variables['elements'][$key];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user