public function PanelizerWizardBase::getOperations in Panelizer 8.3
Same name and namespace in other branches
- 8.5 src/Wizard/PanelizerWizardBase.php \Drupal\panelizer\Wizard\PanelizerWizardBase::getOperations()
- 8.4 src/Wizard/PanelizerWizardBase.php \Drupal\panelizer\Wizard\PanelizerWizardBase::getOperations()
Retrieve a list of FormInterface classes by their step key in the wizard.
Parameters
mixed $cached_values: The values returned by $this->getTempstore()->get($this->getMachineName()); *.
Return value
array An associative array keyed on the step name with an array value with the following keys:
- title (string): Human-readable title of the step.
- form (string): Fully-qualified class name of the form for this step.
- values (array): Optional array of cached values to override when on this step.
- validate (array): Optional array of callables to be called when this step is validated.
- submit (array): Optional array of callables to be called when this step is submitted.
Overrides FormWizardInterface::getOperations
1 call to PanelizerWizardBase::getOperations()
- PanelizerWizardBase::customizeForm in src/
Wizard/ PanelizerWizardBase.php - Helper function for generating default form elements.
File
- src/
Wizard/ PanelizerWizardBase.php, line 88
Class
Namespace
Drupal\panelizer\WizardCode
public function getOperations($cached_values) {
$operations = [
'general' => [
'form' => PanelizerWizardGeneralForm::class,
'title' => $this
->t('General settings'),
],
'contexts' => [
'form' => PanelizerWizardContextForm::class,
'title' => $this
->t('Contexts'),
],
];
// Add any wizard operations from the plugin itself.
foreach ($cached_values['plugin']
->getWizardOperations($cached_values) as $name => $operation) {
$operations[$name] = $operation;
}
// Change the class that manages the Content step.
if (isset($operations['content'])) {
//$operations['content']['form'] = PanelizerWizardContentForm::class;
}
return $operations;
}