Support » Plugin: PDF Invoices & Packing Slips for WooCommerce » Strange total in invoice after update

  • Resolved torbent

    (@torbentschechnegmailcom)


    Hello,
    I did an update to WooCommerce 2.3.13 and since then I see strange things on my invoice.

    If someone orders one magazine I can see as a price:
    12,90 € Enthält 0,84 € reduzierte MwSt. (7%)

    This is german and means:
    12,90 € includes 0,84 € reduced tax (7%)

    Shipping is free, but in the order total I see:
    Gesamtsumme 12,90 €Enthält 25,13 € 1

    Which means:
    Total 12,90 €includes 25,13 € 1

    I do not know what happened here, but normally it should display the total and the included tax…. How can I fix this? In my custom template it is used:

    <table class="totals">
    					<tfoot>
    						<?php foreach( $wpo_wcpdf->get_woocommerce_totals() as $key => $total ) : ?>
    						<tr class="<?php echo $key; ?>">
    							<td class="no-borders">&nbsp;</td>
    							<th class="description"><?php echo $total['label']; ?></th>
    							<td class="price"><span class="totals-price"><?php echo $total['value']; ?></span></td>
    						</tr>
    						<?php endforeach; ?>
    					</tfoot>
    				</table>

    https://wordpress.org/plugins/woocommerce-pdf-invoices-packing-slips/

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

    (@pomegranate)

    Hi Torben,
    With the free version/the function for the totals that you are using, the data/text comes straight from WooCommerce. Most likely, in the order confirmation email you’ll see the same. So this is either an issue with WooCommerce itself or an issue with a plugin that filters this. If you are using WooCommerce German Market or WooCommerce Germanized, it’s possible that these are filtering/altering the totals, which could have this effect.

    Let me know if you find a solution, or if for some reason this turns out to be an issue specific to the PDF invoices!

    Ewout

    Thread Starter torbent

    (@torbentschechnegmailcom)

    Hello,
    I use GermanMarket and posted the issue in their support forums as well. They stated the file: inc/class-wcpdf-export.php is calculating the taxes and is not using the data coming from WooCommerce (line 817) – it does not implement the WooCommerce API. They say the issue is in that file.

    Can you check?

    P.S: Is the PRO version of your plugin doing this in another way than the free version?

    Plugin Contributor Ewout

    (@pomegranate)

    Hi Torben,
    Those functions are not used for the free Simple template, you can refer them to this code (relevant lines are highlighted):
    https://github.com/wpovernight/woocommerce-pdf-invoices-packing-slips/blob/master/woocommerce-pdf-invoices-packingslips.php#L650-L668

    As you can see, the totals are not altered by the plugin, but come straight from $order->get_order_item_totals().

    Ewout

    Thread Starter torbent

    (@torbentschechnegmailcom)

    Thanks. Will keep you posted.

    Plugin Contributor Ewout

    (@pomegranate)

    Great, thanks!

    I didn’t see your P.S.!
    The Professional extension uses the simple template with the same totals as you currently have (for invoice, proforma invoice and credit note), but if you’re using the Premium templates, you can fully configure the totals to your specific needs (deciding what is displayed and in which order), and those woocommerce totals are not used.

    Thread Starter torbent

    (@torbentschechnegmailcom)

    The issue was caused by GermanMarket.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Strange total in invoice after update’ is closed to new replies.