public function Menu::__construct in Forena Reports 8
Same name and namespace in other branches
- 7.5 src/Menu.php \Drupal\forena\Menu::__construct()
File
- src/
Menu.php, line 35 - Menu.inc Drupal menu builder @author davidmetzler
Class
Namespace
Drupal\forenaCode
public function __construct() {
$docs = \Drupal::config('forena.settings')
->get('doc_defaults');
// Load settings array into normal array
if ($docs) {
foreach ($docs as $doc => $enabled) {
if ($enabled) {
$this->doc_defaults[] = $doc;
}
}
}
else {
$this->doc_formats = array(
'web',
);
}
// Load settings array into normal array
$docs = \Drupal::config('forena.settings')
->get('doc_formats');
if ($docs) {
foreach ($docs as $doc => $enabled) {
if ($enabled) {
$this->doc_formats[] = $doc;
}
}
}
}