Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add: updated payment gateways for 2023 Q3 #38646

Merged
merged 1 commit into from Jun 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -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',
ilyasfoo marked this conversation as resolved.
Show resolved Hide resolved
)
),
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