All media (pdfs) table and how to make an open and download buttons for each record (for each pdf)
Hello.
My users add several pdfs in several pages and now I want to make a resource for ALL PDFS, where every record is one only PDF. I already have that, coming from the table with name "media", but I cannot add a link or button to open the file in new tab and and another one for download.
I am using Spatie Media Library but cannot find the right help for this. I really have all the information I need in that file called "media"
I have tried this
but I get the error:
Typed property Filament\Forms\Components\Component::$container must not be accessed before initialization
for the first line with $get
I have also tried an Action button like this:
but nothing seems to happen.
Could anybody please give me hint of the right approach for this?
Thanks a lot.
2 Replies
Leandro Ferreira gave a solutions here for the url link.
https://discord.com/channels/883083792112300104/1154117866774335508/1154233296918696046
Anyway, I would like to have two action buttons for every record in the table: open PDF and DOWNLOAD pdf.
Any ideas of how to put those as action buttons in table?
Tks
Thanks for your tip @Albert Lens, it also helped me!