Skip to content

Commit

Permalink
add: updated payment gateways for 2023 Q3 (#38646)
Browse files Browse the repository at this point in the history
  • Loading branch information
rjchow committed Jun 9, 2023
1 parent 622711c commit e68ff84
Show file tree
Hide file tree
Showing 2 changed files with 62 additions and 9 deletions.
@@ -0,0 +1,4 @@
Significance: minor
Type: add

Updated payment gateway suggestions for 2023 Q3
Expand Up @@ -390,10 +390,57 @@ public static function get_all() {
'image_72x72' => WC_ADMIN_IMAGES_FOLDER_URL . '/payment_methods/72x72/paypal.png',
'plugins' => array( 'woocommerce-paypal-payments' ),
'is_visible' => array(
(object) array(
'type' => 'base_location_country',
'value' => 'IN',
'operation' => '!=',
self::get_rules_for_countries(
array(
'US',
'CA',
'MX',
'BR',
'AR',
'CL',
'CO',
'EC',
'PE',
'UY',
'VE',
'AT',
'BE',
'BG',
'HR',
'CH',
'CY',
'CZ',
'DK',
'EE',
'ES',
'FI',
'FR',
'DE',
'GB',
'GR',
'HU',
'IE',
'IT',
'LV',
'LT',
'LU',
'MT',
'NL',
'NO',
'PL',
'PT',
'RO',
'SK',
'SL',
'SE',
'AU',
'NZ',
'HK',
'JP',
'SG',
'CN',
'ID',
)
),
self::get_rules_for_cbd( false ),
),
Expand Down Expand Up @@ -446,7 +493,6 @@ public static function get_all() {
'SG',
'CN',
'ID',
'IN',
),
'category_additional' => array(
'US',
Expand Down Expand Up @@ -500,6 +546,7 @@ public static function get_all() {
'SG',
'CN',
'ID',
'IN',
),
),
array(
Expand Down Expand Up @@ -677,6 +724,7 @@ public static function get_all() {
'AR',
'CL',
'CO',
'EC',
'PE',
'UY',
'MX',
Expand All @@ -689,6 +737,7 @@ public static function get_all() {
'AR',
'CL',
'CO',
'EC',
'PE',
'UY',
'MX',
Expand Down Expand Up @@ -1107,7 +1156,7 @@ private static function get_recommendation_priority( $gateway_id, $country_code
'BO' => [],
'CL' => [ 'woo-mercado-pago-custom', 'ppcp-gateway' ],
'CO' => [ 'woo-mercado-pago-custom', 'ppcp-gateway' ],
'EC' => [ 'ppcp-gateway' ],
'EC' => [ 'woo-mercado-pago-custom', 'ppcp-gateway' ],
'FK' => [],
'GF' => [],
'GY' => [],
Expand Down Expand Up @@ -1153,9 +1202,9 @@ private static function get_recommendation_priority( $gateway_id, $country_code
'GU' => [],
'ID' => [ 'stripe', 'ppcp-gateway' ],
'IN' => [ 'stripe', 'razorpay', 'payubiz', 'ppcp-gateway' ],
'ZA' => [ 'payfast', 'paystack', 'ppcp-gateway' ],
'NG' => [ 'paystack', 'ppcp-gateway' ],
'GH' => [ 'paystack', 'ppcp-gateway' ],
'ZA' => [ 'payfast', 'paystack' ],
'NG' => [ 'paystack' ],
'GH' => [ 'paystack' ],
);

// If the country code is not in the list, return default priority.
Expand Down

0 comments on commit e68ff84

Please sign in to comment.