• Resolved korynorthrop

    (@korynorthrop)


    I built a custom template for my Invoice and Packing Slips using this great plugin. I would like to add two more things to the Invoices: “Amount Paid” and “Balance Due:”. I can’t seem to find any methods/functions that allow me to glean that information from the Order. Is this available somehow? All I really need is the Amount Paid because I’ll subtract that number from the grand total to get the Balance Due.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor Ewout

    (@pomegranate)

    Hi! WooCommerce does not have built in methods to do partial/pre-payments, so I’m guessing you’re using a plugin for this purpose? The developers of this plugin should be able to help you get this information.

    If you would like to do some digging yourself, you could check our guide Finding WooCommerce Custom Fields and then pull that data into the template by using meta getters like this:

    
    $balance_due = $this->order->get_meta('_your_meta_data_key');
    

    Hope that helps!

    Ewout

    Thread Starter korynorthrop

    (@korynorthrop)

    Thanks for your reply. My client just told me that they aren’t actually accepting partial payments, they just wanted to include Amount Paid and Balance Due on the invoice to reflect whether the Order was paid or not. Your response is useful to know going forward, though. I appreciate it.

    Plugin Contributor Ewout

    (@pomegranate)

    Ah I see – in that case you could just check $this->order->is_paid().

    Thread Starter korynorthrop

    (@korynorthrop)

    That works great. Thanks again for your quick support.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Amount Owed’ is closed to new replies.