Automatically generate index.
-
Good afternoon! Is there any possibility to automatically add an index of the titles on the first page?
For example.Title 1 ........................................................ Page 1
Title 2 ........................................................ Page 3
Title 3 ........................................................ Page 8From already thank you very much.
Greetings from Argentina.
-
The table of contents can be implemented using pdf utils extension in jsreport.
See the documentation
https://jsreport.net/learn/pdf-utils#toc-table-of-contentsAnd the demo
https://playground.jsreport.net/w/admin/akYBA4rS
-
Perfect, thank you very much.
An additional consultation. I tried the example with "toc" in "prepend" instead of "merge". Do I access "@root" from a "prepend" file instead of "merge"?
Many thanks. Regards.
-
Could you elaborate more?
The input data for the prepend operation are the same as for the original template plus additional$pdf
property with currently parsed pdf.
Note if you are trying to simplify TOC generation using prepend, you will be able to reach the same result, but without TOC clickable.
-
Perfect, thank you very much.
I thought that "prepend" does not work for me because I was doing something wrong!
Her explanation was very clear to me.
Many thanks. You guys are cracks!