diff --git a/src/Gateway.php b/src/Gateway.php index abaed36..126d4fd 100644 --- a/src/Gateway.php +++ b/src/Gateway.php @@ -17,9 +17,7 @@ use Pronamic\WordPress\Pay\Core\PaymentMethods; use Pronamic\WordPress\Pay\Core\PaymentMethodsCollection; use Pronamic\WordPress\Pay\Fields\CachedCallbackOptions; -use Pronamic\WordPress\Pay\Fields\DateField; use Pronamic\WordPress\Pay\Fields\IDealIssuerSelectField; -use Pronamic\WordPress\Pay\Fields\SelectField; use Pronamic\WordPress\Pay\Fields\SelectFieldOption; use Pronamic\WordPress\Pay\Payments\Payment; use Pronamic\WordPress\Pay\Refunds\Refund; @@ -87,47 +85,6 @@ function () { $ideal_payment_method->add_field( $ideal_issuer_field ); - /* - * Payment method AfterPay.nl. - */ - $afterpay_payment_method = new PaymentMethod( PaymentMethods::AFTERPAY_NL ); - - // Gender field. - $field_gender = new SelectField( 'pronamic_pay_gender' ); - - $field_gender->meta_key = 'gender'; - - $field_gender->set_label( \__( 'Gender', 'pronamic_ideal' ) ); - - $field_gender->set_options( - [ - new SelectFieldOption( Gender::FEMALE, \__( 'Female', 'pronamic_ideal' ) ), - new SelectFieldOption( Gender::MALE, \__( 'Male', 'pronamic_ideal' ) ), - new SelectFieldOption( '', \__( 'Other', 'pronamic_ideal' ) ), - ] - ); - - $afterpay_payment_method->add_field( $field_gender ); - - // Date of birth field. - $field_birth_date = new DateField( 'pronamic_pay_birth_date' ); - - $field_birth_date->meta_key = 'birth_date'; - - $field_birth_date->set_label( \__( 'Date of birth', 'pronamic_ideal' ) ); - - $afterpay_payment_method->add_field( $field_birth_date ); - - $this->register_payment_method( $afterpay_payment_method ); - - // Riverty. - $riverty_payment_method = new PaymentMethod( PaymentMethods::RIVERTY ); - - $riverty_payment_method->add_field( $field_gender ); - $riverty_payment_method->add_field( $field_birth_date ); - - $this->register_payment_method( $riverty_payment_method ); - // Payment methods. $this->register_payment_method( new PaymentMethod( PaymentMethods::BANCONTACT ) ); $this->register_payment_method( new PaymentMethod( PaymentMethods::CREDIT_CARD ) ); diff --git a/src/PaymentBrands.php b/src/PaymentBrands.php index cd3eff0..e053b1b 100644 --- a/src/PaymentBrands.php +++ b/src/PaymentBrands.php @@ -27,15 +27,6 @@ class PaymentBrands { */ const IDEAL = 'IDEAL'; - /** - * Payment brand 'AFTERPAY'. - * - * Note: this is for AfterPay (afterpay.nl) and not for Afterpay (afterpay.com). - * - * @var string - */ - const AFTERPAY = 'AFTERPAY'; - /** * Payment brand 'PAYPAL'. * @@ -104,14 +95,12 @@ class PaymentBrands { * @var array */ private static $map = [ - PaymentMethods::AFTERPAY_NL => self::AFTERPAY, PaymentMethods::BANCONTACT => self::BANCONTACT, PaymentMethods::CREDIT_CARD => self::CARDS, PaymentMethods::IDEAL => self::IDEAL, PaymentMethods::MAESTRO => self::MAESTRO, PaymentMethods::MASTERCARD => self::MASTERCARD, PaymentMethods::PAYPAL => self::PAYPAL, - PaymentMethods::RIVERTY => self::AFTERPAY, PaymentMethods::SOFORT => self::SOFORT, PaymentMethods::VISA => self::VISA, PaymentMethods::V_PAY => self::V_PAY,