News:

Looking for documentation? Take a look on our wiki

Main Menu

VM 3.2.4 - Invoice printing unwanted label - Fix

Started by bcohen0, September 24, 2017, 01:36:11 AM

Previous topic - Next topic

bcohen0

Invoice prints a label with no value, "Tax includes: ". 

In my configuration, I'm showing GST for each product, and have no additional taxes. Invoice is printing this label with no value, but cart is not printing this line. Not-printing is what is wanted, as in cart. Details are as follows:

Looks to me like a change needed in components/com_virtuemart/views/invoice/tmpl/invoice_items.php  line 245

if($taxBill) {


Whereas, in components/com_virtuemart/views/cart/tmpl/default_pricelist.php, line 330

      $c = count($this->cart->cartData['VatTax']);
      if (!VmConfig::get ('show_tax') or $c>1) {
         if($c>0){ ?>



I have overridden components/com_virtuemart/views/invoice/tmpl/invoice_items.php line 245 to say instead (in my template):

if( !VmConfig::get('show_tax') or count($taxBill)>1)  {

This is intended to mirror the behaviour of cart, and seems to work.