Show Prices including Taxes in Backend

  • Posts: 108
  • Thank you received: 4
  • Hikashop Business
12 years 1 month ago #69654

Hello there

Is it possible to display the Prices including the Tax in the Backend? Or even better: Display both?
We have configured a tax since on the invoice sent to the customer, the tax must be displayed. Therefore I have a tax configured on every product, but since we can see the changes of prices better if we could see the price including taxes, this would be nice.

Is there a way to configure / do that?

Best regards and many thanks for a hint!
Mike

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
12 years 1 month ago #69773

Hi mike,

Where do you want that the price with tax must be displayed ?

In the orders,the price is displayed without tax and the tax price is displayed next to it. If you want you can change this view in HikaShop > Display > Views, and edit the file "order / show" in the backend.

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 4
  • Hikashop Business
12 years 4 days ago #78340

Xavier wrote: Hi mike,

Where do you want that the price with tax must be displayed ?

In the orders,the price is displayed without tax and the tax price is displayed next to it. If you want you can change this view in HikaShop > Display > Views, and edit the file "order / show" in the backend.


Sorry, for the late reply. I'm standing shortly before the rollout and was very busy.

I would like to have the prices including Taxes in the Product Overview (HikaShop -> Menu "Products", then click "Products" in the Dropdown). I would like to have the same behavior in the "Variants"-Table of a product.

What Backend-Script generates these tables? I was not able to find it.

The point why I would like to have this is because, from all our suppliers, we get price lists with 8% Tax included. So when I get a new price list, I can quickly check through the prices.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
12 years 4 days ago #78356

Hi,

If you have only one tax, you can edit the view "product / listing" in the backend.
And replace the line:

<?php echo $this->currencyHelper->displayPrices(@$row->prices); ?>
By:
<?php echo $this->currencyHelper->displayPrices(@$row->prices * 1.008); ?>

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 4
  • Hikashop Business
12 years 4 days ago #78368

Hello there
Thank you for that quick response!
Unfortunately I have no only 1 Tax.

How is the relation between products / prices / taxes? How can I access these information?

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
12 years 4 days ago #78370

I think that the solution given in this post will be ok:
www.hikashop.com/en/forum/4-how-to/76004...-explorer.html#78022

The following user(s) said Thank You: mike

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 4
  • Hikashop Business
12 years 4 days ago #78371

ohh... this is it! THANK YOU VERY MUCH! I'll try that!!! :woohoo:

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 4
  • Hikashop Business
11 years 11 months ago #79250

Xavier wrote: Hi,

If you have only one tax, you can edit the view "product / listing" in the backend.
And replace the line:

<?php echo $this->currencyHelper->displayPrices(@$row->prices); ?>
By:
<?php echo $this->currencyHelper->displayPrices(@$row->prices * 1.008); ?>


Using the suggested line results in the following error:
Fatal error: Unsupported operand types in /home/waffenma/public_html/shop/administrator/templates/bluestork/html/com_hikashop/product/listing.php on line 303

Is there an incompatibility of the datatypes the problem?

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #79277

Hi,

It's maybe because you can't do the operation in the function call, try that:

<?php 
    $row_prices = @$row->prices * 1.008;
    echo $this->currencyHelper->displayPrices($row_prices); 
?>

Please Log in or Create an account to join the conversation.

  • Posts: 108
  • Thank you received: 4
  • Hikashop Business
11 years 11 months ago #79283

nope, it seems it's still not working:

Fatal error: Unsupported operand types in /home/waffenma/public_html/shop/administrator/templates/bluestork/html/com_hikashop/product/listing.php on line 303

Is there any chance to get the tax-factor via the "product_tax_id" ?

Last edit: 11 years 11 months ago by mike.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #79297

<?php echo $this->currencyHelper->format((int)@$row->prices[0]->price_value * 1.0008, @$row->prices[0]->price_currency_id); ?>

It should be ok with that.

Please Log in or Create an account to join the conversation.

  • Posts: 154
  • Thank you received: 10
11 years 11 months ago #83101

Hi Xavier,

This line works! The only problem is that the original number (4,92) becomes lower with this line:

<?php echo $this->currencyHelper->format((int)@$row->prices[0]->price_value * 1.21, @$row->prices[0]->price_currency_id); ?>

The output of this line is 4.84 where it should be 5.95

So even though it gives me an output and not an error, somewhere the original number is not used i think?


Proud of my website www.hetcomputerwinkeltje.nl

Currently just running catalog mode, but hope to go live soon again :)

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
11 years 11 months ago #83105

Hi,

Try to make the calcul before, like:

<?php 
    $nPrice = (int)@$row->prices[0]->price_value * 1.21;
    echo $this->currencyHelper->format(@$nPrice, @$row->prices[0]->price_currency_id); 
?>

Please Log in or Create an account to join the conversation.

  • Posts: 154
  • Thank you received: 10
11 years 11 months ago #83107

Hi!

Same output :(


Proud of my website www.hetcomputerwinkeltje.nl

Currently just running catalog mode, but hope to go live soon again :)

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13377
  • MODERATOR
11 years 11 months ago #83241

You should try to removing the (int) in that code.

The following user(s) said Thank You: anypc

Please Log in or Create an account to join the conversation.

  • Posts: 154
  • Thank you received: 10
11 years 10 months ago #83776

Didnt get around to testing it yet (Holidays and stuff :) )

Just tested it and it works flawlessly! You rule once again! Thanx Xavier and Nicolas!


Proud of my website www.hetcomputerwinkeltje.nl

Currently just running catalog mode, but hope to go live soon again :)

Please Log in or Create an account to join the conversation.

Time to create page: 0.107 seconds
Powered by Kunena Forum