protected function Calendar::getPermittedNodeTypeCreationActions in Content Planner 8
Get all permitted Node Type Creation actions.
Return value
array
1 call to Calendar::getPermittedNodeTypeCreationActions()
- Calendar::build in modules/
content_calendar/ src/ Component/ Calendar.php - Creates the render array for the calendar.
File
- modules/
content_calendar/ src/ Component/ Calendar.php, line 137
Class
Namespace
Drupal\content_calendar\ComponentCode
protected function getPermittedNodeTypeCreationActions() {
$permitted_node_types = [];
foreach ($this->contentTypeConfigEntities as $node_type => $config_entity) {
if ($this->user
->hasPermission("create {$node_type} content")) {
$permitted_node_types[$node_type] = $config_entity;
}
}
return $permitted_node_types;
}