How to modify UltimatePDF to force cover image?

Hi everyone,
Does anyone know where and what needs to be changed in the UltimatePDF module to force the cover image?
My Dolibarr is synchronised with my Presta Shop and I create the products in PrestaShop. Once a product is created in Prestashop it appears in Dolibarr with all the images. The images names look like that XXXX-XXXX.jpeg and all the cover images contain word “cover” coverXXXX-XXXX.jpeg
At the moment to display the product images in the PDF document I need to change the displayed image eg. to 8888.jpeg so the document displays the cover instead of a random picture. It is very time consuming but not so bad if the product has 2-3 images but if the product has more eg. 10 images it takes ages to work out the names for the images so they are displayed properly.



@pscoffoni can you help with it?

Has anyone managed to solve this problem?