/** * Constructs and initialize iDEAL gateway. */ public function __construct() { parent::__construct(); // Set the name of this gateway. // @see https://gitlab.com/pronamic/memberpress/blob/1.2.4/app/lib/MeprBaseGateway.php#L12-13 $this->name = __('Bank Transfer', 'pronamic_ideal'); $this->payment_method = Pronamic_WP_Pay_PaymentMethods::BANK_TRANSFER; }
/** * Constructs and initialize credit card gateway */ public function __construct() { parent::__construct(); // Set the name of this gateway. // @see https://gitlab.com/pronamic/memberpress/blob/1.2.4/app/lib/MeprBaseGateway.php#L12-13 $this->name = __('Credit Card', 'pronamic_ideal'); $this->payment_method = Pronamic_WP_Pay_PaymentMethods::CREDIT_CARD; }
/** * Constructs and initialize direct debit gateway */ public function __construct() { parent::__construct(); // Set the name of this gateway. // @see https://gitlab.com/pronamic/memberpress/blob/1.2.4/app/lib/MeprBaseGateway.php#L12-13 $this->name = __('Direct Debit', 'pronamic_ideal'); $this->payment_method = Pronamic_WP_Pay_PaymentMethods::DIRECT_DEBIT; }
/** * Constructs and initialize iDEAL gateway. */ public function __construct() { parent::__construct(); // Set the name of this gateway. // @see https://gitlab.com/pronamic/memberpress/blob/1.2.4/app/lib/MeprBaseGateway.php#L12-13 $this->name = __('Bancontact/Mister Cash', 'pronamic_ideal'); $this->payment_method = Pronamic_WP_Pay_PaymentMethods::MISTER_CASH; }
/** * Update lead status of the specified payment * * @see https://github.com/Charitable/Charitable/blob/1.1.4/includes/gateways/class-charitable-gateway-paypal.php#L229-L357 * @param Pronamic_Pay_Payment $payment */ public static function status_update(Pronamic_Pay_Payment $payment) { global $transaction; $transaction_id = $payment->get_source_id(); $transaction = new MeprTransaction($transaction_id); $should_update = !Pronamic_WP_Pay_Extensions_MemberPress_MemberPress::transaction_has_status($transaction, array(MeprTransaction::$failed_str, MeprTransaction::$complete_str)); if ($should_update) { $gateway = new Pronamic_WP_Pay_Extensions_MemberPress_Gateway(); switch ($payment->get_status()) { case Pronamic_WP_Pay_Statuses::CANCELLED: case Pronamic_WP_Pay_Statuses::EXPIRED: case Pronamic_WP_Pay_Statuses::FAILURE: $gateway->record_payment_failure(); break; case Pronamic_WP_Pay_Statuses::SUCCESS: $gateway->record_payment(); break; case Pronamic_WP_Pay_Statuses::OPEN: default: break; } } }