You are here

public function SitewideAlertRevisionRevertForm::buildForm in Sitewide Alert 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

1 call to SitewideAlertRevisionRevertForm::buildForm()
SitewideAlertRevisionRevertTranslationForm::buildForm in src/Form/SitewideAlertRevisionRevertTranslationForm.php
Form constructor.
1 method overrides SitewideAlertRevisionRevertForm::buildForm()
SitewideAlertRevisionRevertTranslationForm::buildForm in src/Form/SitewideAlertRevisionRevertTranslationForm.php
Form constructor.

File

src/Form/SitewideAlertRevisionRevertForm.php, line 105

Class

SitewideAlertRevisionRevertForm
Provides a form for reverting a Sitewide Alert revision.

Namespace

Drupal\sitewide_alert\Form

Code

public function buildForm(array $form, FormStateInterface $form_state, $sitewide_alert_revision = NULL) {
  $this->revision = $this->SitewideAlertStorage
    ->loadRevision($sitewide_alert_revision);
  $form = parent::buildForm($form, $form_state);
  return $form;
}