Add Line Number Trick

Hello All

Just found a little trick which is making my life a lot easier and thought I would share it with every body.

Since v4.0 a new HIDDEN OPTION was introduced.

NEW: Can select dynamically number of lines to show on page on product, shipment, contact, orders, third parties.

For those of us who have long lists of products/services in our orders/invoices etc, this feature adds a line number next to each item for easier reference.

To Activate:
Go to SETUP>OTHER SETUP and set the following:
Name: MAIN_VIEW_LINE_NUMBER
Value: 1

Please mark the post as ‘Thank You’ if you found this useful.

5 Likes

Hi Aljawaid!

Thank you very much for sharing this tipp, I have been searching pretty intense for this I am glad this does the trick.
Anyway, how do you implement this into your invoice? I tried quite a few like {line_colnum} and others and I googled like crazy.

Any clue how to get the numbers actually showing up in the final document?

Thanks in advance!!

Anyone??

Someone knows how to number in the template

Hi everyone

Ultimatepdf can do the job for all kind of documents.
you can see an example here

@+
Philippe

Pièces jointes :

1 Like

Thanks for the information Philippe,

it would help to use this tool, if we used PDF as a export format.
We are now pretty much done with the templates as ODT and we like the possibility to tweak little details after generating an invoice.

As I understand it, the numbers are there in my Dolibarr invoice, but I just don’t know how to call them in my template.

Any ideas?

Cheers
Bernd

And what else is there? I would be interested. But I would also like this invoice number to be reset every month. The photograph is inserted FA 1701-0028
And I would like to be allocated one year from the month. eg. FA 0028/01/17 And yet he would like the price summary to be in words.

The trick not work on proposal pdf ??

1 Like

Hello All

I found this in the Dolistore. It is priced low and base don the screenshot it seems to do the trick. The only problem is that besides a screenshot there is no other information or developer contact details.

https://www.dolistore.com/en/modules/808-Invoice-template-with-lines.html

If anyone uses this module, kindly explain if the line numbers show in existing core pdf templates or in a separate one and which templates it works on.

Thanks.

Hi, thanks for the tip. I purchased this code, but it seems not yet to do the trick

  1. the language is different
  2. the column width is not automatically corrected.
  3. the lines do not count.
  4. it only works on the invoice, not on proposals or delivery notes

So basically this was 12 Euro not spend too well, but well worth trying :-). Attached a cutout of the invoices, with and without using the option.
I woiuld be very pleased if someone can come up with a better solution. I am also looking for this option for quite some time now.

Thanks alraedy

Pièces jointes :

2 Likes

Hey everyone,

as far as I can see dolibarr doesn’t offer something out of the box.
So I looked up someone professional, who helped me sort this out.

I’m very happy with the result, so I can recommend him.
Just drop him a note, it’s ok for him that I post his details.

Omar Bouguima: omar.bouguima@gmail.com

Best regards
Bernd

1 Like

The trick is simple. Just make a column of table to be with Numbering option. For your reference I have attached a image of how I did it. The challenge I faced during the process is the code. Whenever I saved the edited document from libre writer, there was error. So I did editing initially in Word, then copied the calling code from Notepad++ and pasted as shown in Picture.

Unbenannt.jpg

For those of you looking into a line numbering system, there is now a great solution. After contacting Patrick Fox, he was willing to write a complete module, doing just this. It shows on screen and on all print outs. Plus his support is fantastic, fast and accurate. He put this module in the Dolistore, for a reasonable price, so have a look.
Check this link https://www.dolistore.com/en/modules/898-Line-Numbers.html

I had lots of issues creating ODT templates in Libre but OpenOffice seems to work great.

but this will not reflect in pdf document

It does not even work in ODT-template because one does not know how to call it.

Hi

Below line in change log of Dolibarr 15.0.1 suggests to use {line_pos} tag to generate line item number.

./ChangeLog:1623:NEW: Support of tag {line_pos} for line numbers for tables in ODT templates

You can check in line number 597 of htdocs/core/class/commondocgenerator.class.php about this.

Try using the tag {line_pos} and post your findings.

thanks
yesbee

Hi
Thank you for the info, I am trying to use in Dolibarr 18 but don’t work, can explain all the modifications that I have to do.