How 2 display the GST Rate [localtax1& localtax2]

How do I display the localtax1 and localtax2 rates in custom ODT. What are the tags for them. I can get the total numerical value but not the percentages to display in the table.

crabe generates it seamlessly however, I am unable to achieve the same.

Any help in this regard would be appreciated.

Guys any help on this?

Hi,

Evertihing is in there : https://wiki.dolibarr.org/index.php/Create_an_ODT_document_template

The localtax1 and localtax2 rates TAG doesn’t exist.

Either you create it by your self or you open a Feature Request on Git : https://github.com/Dolibarr/dolibarr/issues

Hi,

I tried creating it. However couldn’t achieve the desired results.

There should be a simpler method as the same is achieved in the crabe file

Could you please guide me on this.

I couldn’t achieve the desired results.
192.168.0.1

Hi,

So this is the edit suggested by Eldy and I believe it should be included in the future updates.

Update your file located in htdocs/core/class/ and edit the file commondocgenerator.php

Delete line number 542 which should be ‘line_up’=>price2num($line->subprice),

and add the following 3 lines

'line_localtax1_vatrate'=>vatrate($line->localtax1_tx), 'line_localtax2_vatrate'=>vatrate($line->localtax1_tx), 'line_up'=>price2num($line->subprice),

Then in your ODT use the tag line_localtax1_vatrate and line_localtax2_vatrate

Thats it.

Here is eldy’s github commit link

Thanks,

So it will be integrated in V10…

Dont know which version it would include probably in 9.0.2. If they release one before V10

This lead me into another problem in my ODT.

In my product description and rate table if I have 3 rows of products a table of only 3 rows is generated whereas in crabe module we have a set table size so it doesn’t matter if you have 2 product rows or 10 product rows. Trying to figure out a similar set up in my ODT.

How can it be achieved?