# To add the 'Linked File' feature to permissions and to generate a PDF output

**URL:** <https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431>\
**Category:** HR modules\
**Created:** [June 12, 2024, 7:27am UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431 "2024-06-12T07:27:59Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![meric](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/m/6bbea6/32.png) [@meric](https://www.dolibarr.org/forum/u/meric)\
**Post date:** [June 12, 2024, 7:27am UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/1 "2024-06-12T07:27:59Z")

</div>

Hello,

“I’m very new to using Dolibarr. I want to add the ‘Linked File’ feature shown in the image below to the permissions module. I want someone with permissions to be able to get a PDF output of this. How can I do this easily?”

 ![foto](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/c/c4feb926edeb3e58a20331318ada85658e004606.jpeg)

---

<div class="post-metadata">

**Author:** ![jonbendtsen](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/977dab/32.png) [@jonbendtsen](https://www.dolibarr.org/forum/u/jonbendtsen)\
**Post date:** [June 12, 2024, 9:50am UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/2 "2024-06-12T09:50:58Z")

</div>

> [@meric](#):
>
> I want someone with permissions to be able to get a PDF output of this.

You want a PDF output that shows a list of all the linked files?

---

<div class="post-metadata">

**Author:** ![jonbendtsen](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/977dab/32.png) [@jonbendtsen](https://www.dolibarr.org/forum/u/jonbendtsen)\
**Post date:** [June 12, 2024, 9:56am UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/3 "2024-06-12T09:56:25Z")

</div>

No, I think you want something else. I can not see the URLs of the page you want it added on, that would be nice to have too, because it reveals which file to edit.

---

<div class="post-metadata">

**Author:** ![meric](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/m/6bbea6/32.png) [@meric](https://www.dolibarr.org/forum/u/meric)\
**Post date:** [June 12, 2024, 11:33am UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/4 "2024-06-12T11:33:02Z")

</div>

Hello Sir,

I want to generate a holiday leave form in PDF format.

Sample.

 ![sss](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/0/0dd1866bd7936d21257df626018378e5ec9d6943.jpeg)  
 ![yy](https://www.dolibarr.org/forum/uploads/dolibarrorg/original/2X/9/9a8509dc6361a8e37612412fbc9f518d651d8885.jpeg)

---

<div class="post-metadata">

**Author:** ![jonbendtsen](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/977dab/32.png) [@jonbendtsen](https://www.dolibarr.org/forum/u/jonbendtsen)\
**Post date:** [June 12, 2024, 1:54pm UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/5 "2024-06-12T13:54:24Z")

</div>

> [@meric](#):
>
> I want to generate a holiday leave form in PDF format.

aha, I see, makes more sense now. Don’t restrict it to only holiday leave, think of maternity leave too + possibly other kinds of leaves.

---

<div class="post-metadata">

**Author:** ![meric](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/m/6bbea6/32.png) [@meric](https://www.dolibarr.org/forum/u/meric)\
**Post date:** [June 12, 2024, 2:06pm UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/6 "2024-06-12T14:06:44Z")

</div>

“Yes, I think so too. However, I don’t know how to do it.”

---

<div class="post-metadata">

**Author:** ![jonbendtsen](https://www.dolibarr.org/forum/letter_avatar_proxy/v4/letter/j/977dab/32.png) [@jonbendtsen](https://www.dolibarr.org/forum/u/jonbendtsen)\
**Post date:** [June 12, 2024, 2:40pm UTC](https://www.dolibarr.org/forum/t/to-add-the-linked-file-feature-to-permissions-and-to-generate-a-pdf-output/25431/7 "2024-06-12T14:40:13Z")

</div>

1. IF you use your dolibarr in a production setting, then you need to do an additional installation of dolibarr that you can use purely for development. Select the newest version possible.

2. create a github account

3. Fork this project [GitHub - Dolibarr/dolibarr: Dolibarr ERP CRM is a modern software package to manage your company or foundation's activity (contacts, suppliers, invoices, orders, stocks, agenda, accounting, ...). it's an open source Web application (written in PHP) designed for businesses of any sizes, foundations and freelancers.](https://github.com/Dolibarr/dolibarr)

4. then clone your forked project to your own harddisk and create a new branch

5. you probably need to change files under this directory dolibarr/htdocs/holiday

6. when you have made changes to a file(s), then copy only those files into your development dolibarr installation and start testing it.

7. when you have a well working solution then commit the changes to your new git branch, push it to your forked github repo and from there create a merge request to get it back into Dolibarr. Then you need to wait until it is merged into dolibarr and then wait more until a new version - with your changes - are released and then you can install that into production.

As for HOW to change the files and implement it. Look at what public functions are available in this file dolibarr/htdocs/holiday/class/holiday.class.php - which you then compare with other class files of dolibarr modules that does have the needed PDF functionality. You can - and should - copy a lot of the needed functionality from other dolibarr files to preserve the same look’n’feel as well as code style.
