You are here

public function YamlFormResultsExportForm::save in YAML Form 8

Form save configuration handler.

Parameters

array $form: An associative array containing the structure of the form.

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

File

src/Form/YamlFormResultsExportForm.php, line 118

Class

YamlFormResultsExportForm
Form for form results export form.

Namespace

Drupal\yamlform\Form

Code

public function save(array &$form, FormStateInterface $form_state) {

  // Save the export options to the form's state.
  $export_options = $this->submissionExporter
    ->getValuesFromInput($form_state
    ->getValues());
  $this->submissionExporter
    ->setYamlFormOptions($export_options);
  drupal_set_message($this
    ->t('The download settings have been saved.'));
}