You are here

public function PayPalPaymentMethodPluginBase::submitConfigurationForm in Ubercart 8.4

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 PaymentMethodPluginBase::submitConfigurationForm

1 call to PayPalPaymentMethodPluginBase::submitConfigurationForm()
PayPalExpressCheckout::submitConfigurationForm in payment/uc_paypal/src/Plugin/Ubercart/PaymentMethod/PayPalExpressCheckout.php
Form submission handler.
2 methods override PayPalPaymentMethodPluginBase::submitConfigurationForm()
PayPalExpressCheckout::submitConfigurationForm in payment/uc_paypal/src/Plugin/Ubercart/PaymentMethod/PayPalExpressCheckout.php
Form submission handler.
PayPalPaymentsStandard::submitConfigurationForm in payment/uc_paypal/src/Plugin/Ubercart/PaymentMethod/PayPalPaymentsStandard.php
Form submission handler.

File

payment/uc_paypal/src/Plugin/Ubercart/PaymentMethod/PayPalPaymentMethodPluginBase.php, line 78

Class

PayPalPaymentMethodPluginBase
Defines the PayPal Express Checkout payment method.

Namespace

Drupal\uc_paypal\Plugin\Ubercart\PaymentMethod

Code

public function submitConfigurationForm(array &$form, FormStateInterface $form_state) {
  $this->configuration['wps_email'] = trim($form_state
    ->getValue('wps_email'));
  $this->configuration['wpp_server'] = $form_state
    ->getValue('wpp_server');
  $this->configuration['api']['api_username'] = $form_state
    ->getValue([
    'settings',
    'api',
    'api_username',
  ]);
  $this->configuration['api']['api_password'] = $form_state
    ->getValue([
    'settings',
    'api',
    'api_password',
  ]);
  $this->configuration['api']['api_signature'] = $form_state
    ->getValue([
    'settings',
    'api',
    'api_signature',
  ]);
}