Jump to content

Question about tax


kevpoll

Recommended Posts

things that make you go uhm...

 

You could just modify the modules/blockcart.tpl

 

here is the code in a native theme 1.4.9.0 (at or near line 137)

 

  {if $priceDisplay == 1}
   <p id="cart-price-precisions">
 {l s='Prices are tax excluded' mod='blockcart'}
   </p>
  {/if}

 

Please remember to force smarty compile when testing .tpl files..

Link to comment
Share on other sites

Found this:

 

</tr>
   {/if}
  {/if}
  <tr
class="cart_total_price">
   <td colspan="5">{l s='Total (tax excl.):'}</td>
  <td colspan="2" class="price" id="total_price_without_tax">{displayPrice
price=$total_price_without_tax}</td>
  </tr>
  <tr class="cart_total_tax">
  <td colspan="5">{l s='Total tax:'}</td>
   <td colspan="2"
class="price" id="total_tax">{displayPrice price=$total_tax}</td>
  </tr>

 

in file themes/default/shopping-cart.tpl

 

I know this will need to be changed but I don't really know what to do. Anyone got any ideas?

Link to comment
Share on other sites

I've changed the following text:

 

</tr>
{/if}
  {/if}
  <tr
class="cart_total_price">
<td colspan="5">{l s='Total (tax excl.):'}</td>
  <td colspan="2" class="price" id="total_price_without_tax">{displayPrice
price=$total_price_without_tax}</td>
  </tr>
  <tr class="cart_total_tax">
  <td colspan="5">{l s='Total tax:'}</td>
<td colspan="2"
class="price" id="total_tax">{displayPrice price=$total_tax}</td>
  </tr>

 

in file themes/default/shopping-cart.tpl to this

 

</tr>
{/if}
  {/if}
  <tr
class="cart_total_price">
<td colspan="5">{l s='Total'}</td>
  <td colspan="2" class="price" id="total_price_without_tax">{displayPrice
price=$total_price_without_tax}</td>
  </tr>

 

It's only a temporary solution as all future versions would have to also be edited which is a real pain. If the code could be altered by prestashop to only display the tax sections when tax in enabled that would be much better.

  • Like 1
Link to comment
Share on other sites

Aloha!

 

There is another way ....

 

In the back office, the tools tab has a translations sub tab. Translations really should be thought of as a text editor for all your component pages and modules. Click on the spinner box to choose what area you want to edit. Then click on the flag representing your language, and you will see all the available lines of text you can edit. If you want to remove a line, then just enter a space in the field, and that will do the trick. Be sure to search (CTRL-F) so that you get all the instances of the text you want to edit or remove, and be sure to save, at the bottom of the page. Also, be sure that preferences/performance SMARTY is set to force compile YES and cache to NO, so that your pages are rebuilt. Once you have everything right, set force compile back to NO and cache to YES, so that your pages load properly.

 

best, Martin

Link to comment
Share on other sites

Hi all, agreed with kevpoll, I have the same problem with the latest stable version (1.5.0.17).

You can switch "display tax in cart" on or off in BO, this has no effect in FO, although PS_TAX_DISPLAY is correctly set in the DB.

Probably some logic i wrong somewhere around the use of $use_taxes in shopping-cart.tpl or we're missing something completely (It worked properly in my previous shop using 1.4).

 

Will have to manually edit the template...

 

Checked the Forge.

Found this issue: http://forge.prestashop.com/browse/PSCFV-1640

 

The answer is:

This option removes the taxes line in the block cart (not on the cart summary).

 

But I might disagree (or not understand the specifics), as shopping_cart.tpl contains the following code:

{if $use_taxes}
  {if $priceDisplay}
   <tr class="cart_total_price">
 <td colspan="5">{if $display_tax_label}{l s='Total products (tax excl.):'}{else}{l s='Total products:'}{/if}</td>
 <td colspan="2" class="price" id="total_product">{displayPrice price=$total_products}</td>
   </tr>
  {else}
   <tr class="cart_total_price">
 <td colspan="5">{if $display_tax_label}{l s='Total products (tax incl.):'}{else}{l s='Total products:'}{/if}</td>
 <td colspan="2" class="price" id="total_product">{displayPrice price=$total_products_wt}</td>
   </tr>
  {/if}
 {else}
  <tr class="cart_total_price">
   <td colspan="5">{l s='Total products:'}</td>
   <td colspan="2" class="price" id="total_product">{displayPrice price=$total_products}</td>
  </tr>
 {/if}

 

where taxes and their use are indeed tested. This could mean that it's not the display of taxes in cart that is not properly validated, but their use.

Once again, this worked in 1.4

 

Sincerely

DJM

Edited by cybeardjm (see edit history)
Link to comment
Share on other sites

OK, Mea Culpa!!!

In fact, what happens is not at all connected with the 2 backoffice values...

It's simply that shopping_cart.tpl has been changed from 1.4 and that these lines were "hardcoded" in the template around line 168:

 

<!--tr class="cart_total_price">
<td colspan="5">{l s='Total (tax excl.):'}</td>
<td colspan="2" class="price" id="total_price_without_tax">{displayPrice price=$total_price_without_tax}</td>
</tr>
<tr class="cart_total_tax">
<td colspan="5">{l s='Total tax:'}</td>
<td colspan="2" class="price" id="total_tax">{displayPrice price=$total_tax}</td>
  </tr-->

Just comment them as I did above, and it's fine.

 

Sincerely

DJM

Edited by cybeardjm (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

i change the code becomes :

 

{if $use_taxes}
  <tr class="cart_total_price">
   <td colspan="5">{l s='Total (tax excl.):'}</td>
   <td colspan="2" class="price" id="total_price_without_tax">{displayPrice price=$total_price_without_tax}</td>
  </tr>
  <tr class="cart_total_tax">
   <td colspan="5">{l s='Total tax:'}</td>
   <td colspan="2" class="price" id="total_tax">{displayPrice price=$total_tax}</td>
  </tr>
  {/if}

 

and it works

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...