Class WC_Braintree_PayPal_Payment_Gateway
- WC_Payment_Gateway
-
WC_Braintree_Payment_Gateway
uses
WC_Braintree_Settings_Trait
-
WC_Braintree_PayPal_Payment_Gateway
Since: 3.0.0
Located at gateways/class-wc-braintree-paypal-payment-gateway.php
Methods summary
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
array
|
|
public
boolean
|
|
public
boolean
|
|
public
string
|
#
get_paypal_flow( string $page = '' )
Returns either "checkout" or "vault" depending on conditions such as if the cart contains subscriptions etc. |
public
|
#
remove_session_checkout_vars( )
Method that is called during successful checkout. It's purpose is to remove any gateway specific variables that are stored in the WC session. |
public
|
|
public
|
#
after_checkout_validation_notice( string $notice, array $data )
Method that adds to the validation notice when the selected payment method is PayPal. |
public
|
|
public
|
|
public
|
#
update_shipping_method_response( array $data )
Decorate the response with data specific to PayPal. |
protected
|
#
add_order_line_items( array & $args, WC_Order $order, array & $items = array() )
Adds the WC_Order line items to the transaction args. For PayPal transactions, the totals must equal the amount property. Totals are calculated by PayPal as follows: taxAmount + shippingAmount + (item['unitAmount'] * item['quantity']). If those values do not equal the amount property, then validation will fail. |
private
|
|
public
array
|
|
public
array
|
#
get_formatted_shipping_method( WC_Shipping_Rate $method, integer $index, boolean $selected, float $amount, integer $decimals )
|
public
|
|
public
|
|
private
array
|
|
private
array
|
|
private
boolean
|
|
public
array
|
|
public
|
|
public
|
Methods inherited from WC_Braintree_Payment_Gateway
add_order_billing_address(),
add_order_customer_id(),
add_order_descriptors(),
add_order_device_data(),
add_order_general_args(),
add_order_options(),
add_order_shipping_address(),
add_order_shipping_amount(),
add_payment_method(),
add_to_cart_response(),
admin_options(),
available_payment_gateways(),
banner_checkout_enabled(),
banner_fields(),
cancel_braintree_subscription(),
capture_charge(),
capture_transaction_from_status(),
cart_checkout_enabled(),
cart_contains_trial_period_subscription(),
cart_fields(),
change_subscription_payment_method(),
connect(),
create_braintree_subscription(),
create_customer(),
delete_payment_method(),
deprecated_subscription_check(),
do_post_payment_processing(),
enqueue_add_payment_method_scripts(),
enqueue_frontend_scripts(),
enqueue_mini_cart_scripts(),
fetch_transaction(),
filter_address_state(),
generate_button_demo_html(),
generate_client_token(),
get_checkout_currency(),
get_config_data(),
get_customer_attributes(),
get_descriptors(),
get_device_data(),
get_display_item_for_cart(),
get_display_item_for_order(),
get_display_item_for_product(),
get_display_items(),
get_display_items_for_cart(),
get_display_items_for_order(),
get_display_items_for_recurring_cart(),
get_display_items_for_subscription(),
get_formatted_shipping_methods(),
get_locale(),
get_new_method_label(),
get_order_id(),
get_order_meta_data(),
get_order_options(),
get_order_total(),
get_payment_method_formats(),
get_payment_method_nonce(),
get_payment_method_token(),
get_payment_token(),
get_saved_method_label(),
get_shipping_method_id(),
get_shipping_packages(),
get_token(),
get_token_type(),
get_transaction_url(),
init(),
init_form_fields(),
is_available(),
is_cart_checkout_enabled(),
is_change_payment_request(),
maybe_enqueue_checkout_scripts(),
mini_cart_enabled(),
mini_cart_fields(),
needs_shipping(),
order_error_result(),
order_success_result(),
output_checkout_fields(),
output_display_items(),
payment_complete_actions(),
payment_fields(),
perform_kount_actions(),
pre_order_before_process_order(),
pre_order_with_payment_later(),
pre_update_payment_method(),
process_change_payment_request(),
process_payment(),
process_pre_order_payment(),
process_refund(),
process_shop_subscription_meta(),
process_subscription_payment(),
product_checkout_enabled(),
product_fields(),
save_order_meta(),
save_zero_total_order_meta(),
set_payment_method_nonce(),
set_payment_method_token(),
set_product_gateway_option(),
should_save_payment_method(),
subscription_payment_meta(),
subscription_payment_method_updated(),
token_exists(),
update_failing_payment_method(),
update_shipping_address_response(),
update_shipping_error(),
use_saved_method(),
validate_fields(),
void_charge(),
void_transaction_from_status(),
wcs_before_process_order(),
wcs_braintree_before_process_order()
Methods used from WC_Braintree_Settings_Trait
admin_settings_tabs(),
generate_button_html(),
generate_description_html(),
generate_multi_select_countries_html(),
generate_multiselect_html(),
generate_paragraph_html(),
generate_slider_html(),
get_admin_localized_params(),
get_braintree_documentation_url(),
get_custom_attribute_html(),
get_localized_params(),
get_prefix(),
get_tab_title(),
is_active(),
output_settings_nav(),
process_admin_options(),
validate_multi_select_countries_field()
Properties summary
protected
boolean
|
$has_digital_wallet
|
#
true
|
protected
int[]
|
$line_item_validations
|
#
array(
'commodityCode' => 12,
'description' => 127,
'discountAmount' => 2,
'name' => 127,
'productCode' => 127,
'taxAmount' => 2,
'totalAmount' => 2,
'unitAmount' => 2,
'unitOfMeasure' => 12,
'unitTaxAmount' => 2,
)
|
protected
string
|
$paypal_flow
|
#
\PaymentPlugins\WC_Braintree_Constants::PAYPAL_CHECKOUT
|
private
string
|
$sandbox_client_id
|
#
'AZDxjDScFpQtjWTOUtWKbyN_bDt4OgqaF4eYXlewfBP4-8aqX3PiV8e1GWU6liB2CUXlkA59kJXE7M6R'
|
Properties inherited from WC_Braintree_Payment_Gateway
$client_token,
$config_key,
$deprecated_id,
$device_data_key,
$gateway,
$nonce_key,
$order_totals,
$payment_method_nonce,
$payment_method_token,
$payment_type_key,
$processing_payment,
$product_gateway_option,
$save_method_key,
$tab_title,
$template,
$token_key,
$token_type,
$update_payment_method_request