Skip to content

Commit

Permalink
Remove Riverty (formerly AfterPay) because Rabobank no longer support…
Browse files Browse the repository at this point in the history
…s it
  • Loading branch information
remcotolsma committed Nov 28, 2023
1 parent 6169e8d commit eda5176
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 54 deletions.
43 changes: 0 additions & 43 deletions src/Gateway.php
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down Expand Up @@ -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 ) );
Expand Down
11 changes: 0 additions & 11 deletions src/PaymentBrands.php
Original file line number Diff line number Diff line change
Expand Up @@ -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'.
*
Expand Down Expand Up @@ -104,14 +95,12 @@ class PaymentBrands {
* @var array<string, string>
*/
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,
Expand Down

0 comments on commit eda5176

Please sign in to comment.