protected function DashboardBlockConfigForm::createInstanceFromBlockId in Content Planner 8
Creates dashboard board plugin instances.
Parameters
string $block_id: The plugin id to create an instance for.
Return value
\Drupal\content_planner\DashboardBlockInterface A dashboard block plugin instance.
2 calls to DashboardBlockConfigForm::createInstanceFromBlockId()
- DashboardBlockConfigForm::buildForm in src/
Form/ DashboardBlockConfigForm.php - Form constructor.
- DashboardBlockConfigForm::validateForm in src/
Form/ DashboardBlockConfigForm.php - Form validation handler.
File
- src/
Form/ DashboardBlockConfigForm.php, line 140
Class
- DashboardBlockConfigForm
- Defines a form that configures forms module settings.
Namespace
Drupal\content_planner\FormCode
protected function createInstanceFromBlockId($block_id) {
$plugin_definition = $this->dashboardBlockPluginManager
->getDefinition($block_id);
return $this->dashboardBlockPluginManager
->createInstance($plugin_definition['id']);
}