protected function PaymentMethodAddForm::buildPayPalForm in Commerce Core 8.2
Builds the PayPal form.
Empty by default because there is no generic PayPal form, it's always payment gateway specific (and usually JS based).
Parameters
array $element: The target element.
\Drupal\Core\Form\FormStateInterface $form_state: The current state of the complete form.
Return value
array The built credit card form.
1 call to PaymentMethodAddForm::buildPayPalForm()
- PaymentMethodAddForm::buildConfigurationForm in modules/
payment/ src/ PluginForm/ PaymentMethodAddForm.php - Form constructor.
File
- modules/
payment/ src/ PluginForm/ PaymentMethodAddForm.php, line 231
Class
Namespace
Drupal\commerce_payment\PluginFormCode
protected function buildPayPalForm(array $element, FormStateInterface $form_state) {
// Placeholder for the PayPal mail.
$element['paypal_mail'] = [
'#type' => 'hidden',
'#value' => '',
];
return $element;
}