You are here

public function LibraryItemRevisionRevertForm::buildForm in Paragraphs 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

modules/paragraphs_library/src/Form/LibraryItemRevisionRevertForm.php, line 140

Class

LibraryItemRevisionRevertForm

Namespace

Drupal\paragraphs_library\Form

Code

public function buildForm(array $form, FormStateInterface $form_state, $paragraphs_library_item_revision = NULL) {
  $this->revision = $this->entityTypeManager
    ->getStorage('paragraphs_library_item')
    ->loadRevision($paragraphs_library_item_revision);
  return parent::buildForm($form, $form_state);
}