0

I have installed the *commerce_kickstart* install profile, and I am wanting to remove the Tax line item on the checkout page, and instead have some text instead that says VAT included (or in my Australia case, GST included).

Everything works well and as expected; however, my client would like to remove the line item for the VAT subtotal and just include text somewhere that says "All prices and totals are inclusive of VAT".

2

Might be a bit late on this one, but there doesn't seem to be a posted solution online. You can remove the tax line using the below.

In your template.php file use the below, this should hide it from your order confirmation email as well. I haven't noticed any problems from this modification, but ymmv. The variation from the standard code is: $rows = array_splice($rows, 2);

function THEME_commerce_price_formatted_components($variables) {
  // Add the CSS styling to the table.
  drupal_add_css(drupal_get_path('module', 'commerce_price') . '/theme/commerce_price.theme.css');

  // Build table rows out of the components.
  $rows = array();

  foreach ($variables['components'] as $name => $component) {
    $rows[] = array(
      'data' => array(
        array(
          'data' => $component['title'],
          'class' => array('component-title'),
        ),
        array(
          'data' => $component['formatted_price'],
          'class' => array('component-total'),
        ),
      ),
      'class' => array(drupal_html_class('component-type-' . $name)),
    );
  }

  $rows = array_splice($rows, 2);

  return theme('table', array('rows' => $rows, 'attributes' => array('class' => array('commerce-price-formatted-components'))));
}
  • Confirmed this works with Drupal 7.56. Ta! – Masa Sakano Oct 23 '17 at 22:14
1

Are your prices already inclusive of tax? If so, I'm fairly sure you just need to make sure there aren't any tax rates defined in Store > Configuration > Taxes then no taxes will be applied.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.