You are here

public function ContactStorageExportForm::buildForm in Contact Storage Export 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 FormInterface::buildForm

File

src/Form/ContactStorageExportForm.php, line 26

Class

ContactStorageExportForm
Settings form for config devel.

Namespace

Drupal\contact_storage_export\Form

Code

public function buildForm(array $form, FormStateInterface $form_state) {
  $contact_form = $this
    ->getRequest()
    ->get('contact_form');
  if ($contact_form) {
    return $this
      ->exportForm($contact_form, $form, $form_state);
  }
  else {
    return $this
      ->contactFormSelection($form, $form_state);
  }
}