From 0135ecb23d0a3735e731b7b1b61edc75249147a9 Mon Sep 17 00:00:00 2001 From: Jeppe Krogh Date: Mon, 16 Dec 2024 14:34:52 +0100 Subject: [PATCH] Set terms urls and payment methods to be required --- src/Plugin/WebformElement/NetsEasyPaymentElement.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Plugin/WebformElement/NetsEasyPaymentElement.php b/src/Plugin/WebformElement/NetsEasyPaymentElement.php index f11df9f..f2cd26e 100644 --- a/src/Plugin/WebformElement/NetsEasyPaymentElement.php +++ b/src/Plugin/WebformElement/NetsEasyPaymentElement.php @@ -99,11 +99,13 @@ public function form(array $form, FormStateInterface $form_state): array { '#type' => 'textfield', '#title' => $this->t('Terms and conditions URL'), '#description' => $this->t('The complete URL to the terms and conditions, including the protocol. Example: https://www.example.com/terms-and-conditions'), + '#required' => TRUE, ]; $form['element']['merchant_terms_url'] = [ '#type' => 'textfield', '#title' => $this->t('The merchant terms URL'), '#description' => $this->t('The complete URL to the merchant terms, including the protocol. Example: https://www.example.com/merchant-terms'), + '#required' => TRUE, ]; $form['element']['payment_posting'] = [ @@ -119,6 +121,7 @@ public function form(array $form, FormStateInterface $form_state): array { 'Card' => $this->t('Kortbetaling'), 'MobilePay' => $this->t('MobilePay'), ], + '#required' => TRUE, ]; return $form;