public function ScannerConfirmUndoForm::buildForm in Search and Replace Scanner 8
Form constructor.
Parameters
array $form: An associative array containing the structure of the form.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.
Return value
array The form structure.
Overrides ConfirmFormBase::buildForm
File
- src/
Form/ ScannerConfirmUndoForm.php, line 28
Class
- ScannerConfirmUndoForm
- Displayed to confirm that the user want to undo the replace operation.
Namespace
Drupal\scanner\FormCode
public function buildForm(array $form, FormStateInterface $form_state, $id = NULL) {
$form = parent::buildForm($form, $form_state);
$form['undo_id'] = [
'#type' => 'hidden',
'#value' => $id,
];
return $form;
}