• Resolved bernardoliveira

    (@bernardoliveira)


    Hello,

    Since I started using this plugin I have this critical error in a custom plugin.

    Error message: Uncaught Error: Call to undefined function wc_gateway_ppec_get_transaction_fee()
    $paypal_fee = wc_gateway_ppec_get_transaction_fee( $order );

    What would be the equivalent function for that in this PayPal plugin?

    Thank you very much!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Syde Niklas

    (@niklasinpsyde)

    Hi @bernardoliveira,

    The name wc_gateway_ppec refers to the PayPal Checkout Payment Gateway. PayPal Payments does not have a transaction fee feature implemented yet, but it will likely come at a later point.
    Could you give us more details on what you are trying to achieve with your custom plugin?
    Thanks!

    Kind regards,
    Niklas

    Thread Starter bernardoliveira

    (@bernardoliveira)

    Hello @niklasinpsyde,

    Thank you for your reply. Hmm, I understand.

    This custom plugin exports all orders to an XML file.

    
    $paypal_fee = wc_gateway_ppec_get_transaction_fee( $order );
    if( $paypal_fee ) {
    $fee = $paypal_fee;
    }
    

    Is there any order day I can make it?

    Thank you very much.

    Plugin Support Syde Niklas

    (@niklasinpsyde)

    Hi @bernardoliveira,

    There is no fee functionality built into PayPal Payments. So if this code causes problems for you when exporting orders paid for with Paypal Payments, then I suggest removing it. To me, it seems only to work for orders paid for with the PayPal Checkout gateway anyway.
    If any questions remain, please let us know. Thanks!

    Kind regards,
    Niklas

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Call to undefined function’ is closed to new replies.