Tax namekey changing

  • Posts: 170
  • Thank you received: 8
  • Hikashop Multisite
2 weeks 1 day ago #314551

-- HikaShop version -- : 4.2.2
-- Joomla version -- : 3.9.13
-- PHP version -- : 7.2

Hi guys,

On the invoice i like to change the namekey so the low and high looks the same.
www.dropbox.com/s/rymxp9p08b3b8uc/Scherm...%2009.58.13.png?dl=0

Now i can't change that name in Hikashop.

How dangerous is it to change that in the database?
Probably a reason why i can't change it :-D

Thanks!

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

  • Posts: 67916
  • Thank you received: 10111
  • MODERATOR
2 weeks 1 day ago #314553

Hi,

You can. Go in the "manage tax rates" button via the System>Taxes menu and create a new tax rate with the namekey you want for your tax rate.
Then, edit your tax rules and change the tax rate to the new one. That way, new orders will use the new tax rate.
Change the tax rate namekey in the database is not a good idea as HikaShop relies on the tax rate namekey when displaying the taxes in the invoice and the backend/frontend as its that namekey which is stored in the order.
So you would have to change the tax namekey in all the orders in the database and it's not easy as the data is serialized in the order information.
Also, you can use translation overrides to change the text.
I suppose you could have a translation override like that:
BTW_HOOG="My custom text"
www.hikashop.com/download/languages.html#modify

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

  • Posts: 170
  • Thank you received: 8
  • Hikashop Multisite
5 days 4 hours ago #314841

Yes then i loose my statistics per tax rate, or need to combine them, Why can't i change a label that is shown to users?
But for next i will use the translation keys.

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

  • Posts: 67916
  • Thank you received: 10111
  • MODERATOR
4 days 20 hours ago #314843

Hi,

Well, even now you can use a translation override to change it. I think that's the best solution here.

Really changing the tax rate name would require modifying all the orders using that tax rate. If you have thousands of orders, it's impossible to do without a crash of PHP on hosting with small resource limitations. And we want to avoid a crash where you would have some orders modified and some not. So that's why we disallow it.
And if we would allow you to change it without changing it in the orders, you would also loose your satistics so that wouldn't be a solution either.

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

Time to create page: 0.061 seconds
Powered by Kunena Forum