You are here

public function TaxTypeBase::submitConfigurationForm in Commerce Core 8.2

Form submission handler.

Parameters

array $form: An associative array containing the structure of the plugin form as built by static::buildConfigurationForm().

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form. Calling code should pass on a subform state created through \Drupal\Core\Form\SubformState::createForSubform().

Overrides PluginFormInterface::submitConfigurationForm

1 call to TaxTypeBase::submitConfigurationForm()
Custom::submitConfigurationForm in modules/tax/src/Plugin/Commerce/TaxType/Custom.php
Form submission handler.
1 method overrides TaxTypeBase::submitConfigurationForm()
Custom::submitConfigurationForm in modules/tax/src/Plugin/Commerce/TaxType/Custom.php
Form submission handler.

File

modules/tax/src/Plugin/Commerce/TaxType/TaxTypeBase.php, line 180

Class

TaxTypeBase
Provides the base class for tax types.

Namespace

Drupal\commerce_tax\Plugin\Commerce\TaxType

Code

public function submitConfigurationForm(array &$form, FormStateInterface $form_state) {
  if (!$form_state
    ->getErrors()) {
    $values = $form_state
      ->getValue($form['#parents']);
    $this->configuration = [];
    $this->configuration['display_inclusive'] = $values['display_inclusive'];
  }
}