mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 10:55:00 +08:00
Merge branch 'trunk' into PCP-726-add-oxxo-apm-alternative-payment
This commit is contained in:
commit
1049fda586
49 changed files with 1586 additions and 668 deletions
|
@ -29,7 +29,7 @@ use WooCommerce\PayPalCommerce\WcGateway\Exception\NotFoundException;
|
|||
use WooCommerce\PayPalCommerce\WcGateway\Gateway\CreditCardGateway;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Gateway\PayPalGateway;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Notice\ConnectAdminNotice;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Notice\DccWithoutPayPalAdminNotice;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Notice\GatewayWithoutPayPalAdminNotice;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Processor\AuthorizedPaymentsProcessor;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Settings\SectionsRenderer;
|
||||
use WooCommerce\PayPalCommerce\WcGateway\Settings\Settings;
|
||||
|
@ -164,11 +164,15 @@ class WCGatewayModule implements ModuleInterface {
|
|||
$notices[] = $connect_message;
|
||||
}
|
||||
|
||||
$dcc_without_paypal_notice = $c->get( 'wcgateway.notice.dcc-without-paypal' );
|
||||
assert( $dcc_without_paypal_notice instanceof DccWithoutPayPalAdminNotice );
|
||||
$dcc_without_paypal_message = $dcc_without_paypal_notice->message();
|
||||
if ( $dcc_without_paypal_message ) {
|
||||
$notices[] = $dcc_without_paypal_message;
|
||||
foreach ( array(
|
||||
$c->get( 'wcgateway.notice.dcc-without-paypal' ),
|
||||
$c->get( 'wcgateway.notice.card-button-without-paypal' ),
|
||||
) as $gateway_without_paypal_notice ) {
|
||||
assert( $gateway_without_paypal_notice instanceof GatewayWithoutPayPalAdminNotice );
|
||||
$message = $gateway_without_paypal_notice->message();
|
||||
if ( $message ) {
|
||||
$notices[] = $message;
|
||||
}
|
||||
}
|
||||
|
||||
$authorize_order_action = $c->get( 'wcgateway.notice.authorize-order-action' );
|
||||
|
@ -294,6 +298,10 @@ class WCGatewayModule implements ModuleInterface {
|
|||
$methods[] = $container->get( 'wcgateway.credit-card-gateway' );
|
||||
}
|
||||
|
||||
if ( $container->get( 'wcgateway.settings.allow_card_button_gateway' ) ) {
|
||||
$methods[] = $container->get( 'wcgateway.card-button-gateway' );
|
||||
}
|
||||
|
||||
if ( 'DE' === $container->get( 'api.shop.country' ) && 'EUR' === $container->get( 'api.shop.currency' ) ) {
|
||||
$methods[] = $container->get( 'wcgateway.pay-upon-invoice-gateway' );
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue