Filament

F

Filament

Filament is a collection of beautiful full-stack components for Laravel.You can get help using it on our Discord.

Join

Download a generated file with Action button

Is there a simple way to download a file by pressing an action button? My code already prepare a proper response with the correct mime type and body but the request is not handled correctly by the browser. If I cannot use a direct download I need to use a URL but I need to send POST inputs to the request as I'm generating a PDF preview of the form....

Form method executing before mount method?

i have this class in an EditFilament component:

Writing unit testing using shield plugin filament for role and permissions

How i can create a unit test for application has a filament plugin shield ?
Solution:
I think actingAs supports guard in the second param..

Can i use regex on TextInput::stripCharacters method?

I have one input masked as '(99) 99999-9999' and i want remove all non numbers characters
Solution:
use dehydrateStateUsing and remove non numbers..
No description

Disable view action when click on row

Hi, how can i disable click on row and open view modal? I only want open modal when i click on View button and not when i click on the row. thanks...

File upload component not validating correctly

In the file upload it says 85KB But the validation error says cannot be greater than 100KB What is happening?...
No description

Location map solution for laravel project

How to Display location map in laravel11? Please help me...

Timeout on specific computer

I have a simple table with 270k records that is working fine for all users. I have a second table with 5k of those 270k records but almost no users can see this page. They all get a timeout and in Sentry i also see the 30 seconds timeout exceeded. If i sign in with their user accounts on my own computer it is working fine. Any reason why this page with table couldnt load on this specific computers?...

Recreating Restaurant Menu Page

Please how possible is it to recreate a page resource like this image in Filament
No description

Dynamic wizard checkboxlist selects all

Good afternoon, on a custom livewire page I have a wizard which the user gets to right after registering their website to us. In the wizard they can configure some things, the second step of the option gives the user a choice between two radio buttons. Dependent on the choice they get a dynamic third step, on of those results is a checkboxlist. But when I click anything they either all select or deselect. I saw some other posts, but I felt like those didn't really apply to this scenario. It's probably a skill issue, but I feel kinda stuck. I hope anyone can help me with this I saw in another post that this worked, but I already have it: ...

Conditionally displaying delete action in a Repeater based on row

Hello, My model has a "active" field that should enable/disable the deletion of the element in the repeater. I know that there's a ->deleteAction(fn ($action) => ...) function, but I haven't been able to figure out how to inject the current row. I tried with $state but the whole repeater array is included instead....

curl error when trying to composer install filament

im getting this error when running composer install even tho i have my credentials in auth.json, and another person is able to succesfully install the project with the same credentials. i have windows 11 and curcl 8.10 installed, i can't seem to find any info on this error online
No description

Custom field with alpinejs function

Hello, I'm trying to create a custom field using Alpine.js code. I've created a simple example to learn how to do this, but it's not working. This is my custom field code:...

How to registerAction on table selectColumn ?

SelectColumn::make('subject')
->options([])
->registerActions()
SelectColumn::make('subject')
->options([])
->registerActions()
...

extra pagination?

my filament table somehow get an extra pagination on top of the original one,i never manually add any pagination.how to remove this extra pagination?
No description

Help with opening modal in Page

Hi, I have a Resource Page I made and I'm trying to add a modal to it but I can't seem to open it using $dispatch. It says $dispatch is not defined. Any idea on how to trigger it? I have a <script> tag inside the page where I have my custom js from which I want to trigger the modal. I've used the info in the docs, if I use a button to trigger it like in the first example everything is ok, just javascript dispatching not working.
Solution:
Ok, apparently I solved it myself. Didn't add my scripts inside @script @endscript tag.

Hello,

I have a fresh Install of Laravel/filament/shield and it works perfectly on local machine. When I uploaded to production via Envoyer/Forge, I had to run php artisan shield:install to create the superadmin. I successfully created user. This user logs in and a 403 error appears. Here is snippet of composer.json... "name": "laravel/laravel",...
Solution:
Thats the point, on local envs you can access all panels, but if your app is in prod you need to have that function on the model, otherwise you'll get 403, if you want the user to have access 100% just make it return true

Can i show infolist page without requiring visitor to log in?

Im building a 3 panel app for 3 different user , first for admin, second for mentor , third for intern. its like a job portal without requiring login to see available position, could you be able to do that in filament v3? please guide im new to filament ,thank you...

How to change page number programmatically in a table

So, I'm trying to to open page 38 automatically when opening a resource table. Currently I use the ListRecords class to redirect with a specific page. Unfortunately it's redirecting to a livewire route instead of the intended route. Is there other strategy I can use?...
No description