Filament

F

Filament

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

Join

How to access form variables (with $get) in a relationship?

I tried to use $get in a relationship, but it can't get a values from a parent form field, only those which are in repeater are accessible , is there any method to access parent form values in a repeater?
Solution:
You can go down a level out of the repeater by using $get('../../answer_type')

Odd "jumping" behaviour when using a toggle

Hi there, in the screen shot you'll see a toggle - it's unpredictable, but sometimes when I toggle the item its position with the folder "group" changes - so you click say the 2nd in the list and the toggle visually updates, the DB updates but there is some kind of refresh going on with the rows in a different order to that expected. Anyone seen this kind of behaviour before?...
No description

Setting/Asserting TableActionData

does ->setTableActionData($data) wipe out default() values for the form even if its not a set in $data and can ->assertTableActionDataSet() check defaults? Was thinking something like ->assertTableActionDataSet([...$data, 'primary_case_manager' => $user->case_manager_id]). Full code being ```php Livewire::test(ListParticipants::class) ->mountTableAction(CreateAction::class) ->setTableActionData($data)...
Solution:
```php Livewire::test(ListParticipants::class) ->mountTableAction(CreateAction::class) ->setTableActionData($data) ->assertFormFieldIsVisible('name', 'mountedTableActionForm')...

disabled button still clickable

I'm using a button blade component, but disabling it makes the appearance change but not the interactivity. The button looks to be disabled, but when you click on it, it still triggers the modal. ```php <x-filament::modal id="myModal" width="6xl">...

How to bind the filters of a filament table created in a livewire component with a widget?

I have made a custom filament table inside a livewire component. I have made it and its working as intented. I have also made a widget that i want to bind to this table so that when i change the filters etc the stats will be automatically updated. In the filament table i have ```php class ReportsFilament extends Component implements HasForms, HasTable { use InteractsWithForms;...

Filament Shield and Filament Socialite login/register issue

Using Filament Socialite (using Microsoft to login) and Filament Shield I cannot login. I first installed Filament Socialite and had the Microsoft login working fine, I then installed Filament Shield and this is when I was unable to login. I can login as the super admin (account made when installing Filament) fine, but not with a new user (using the login via Microsoft)... Cheers, Tee...
Solution:
It is late in the Friday afternoon... My issue was that I deleted the user from users table but did not delete the matching record in socialite_users table!!!
No description

TimePicker

Hi Everyone, how I can make TimePicker::make('time') works with 24 hours and not 12 hours system

image upload using URL

Has anyone managed to create a way to upload media via URL to the https://filamentphp.com/plugins/filament-spatie-media-library plugin? What I've managed to do so far is this: ```php...

Can not get filament views working in 404 view file

Hi! I have this code in my 404.blade.php file: ```php <x-filament::card>...
No description

CreateOption in select on blade/livewire

anyone know how make a createOption in select component in blade/livewire?

Can't pass a tenant parameter to a feature pest test.

Hey, I'm trying to add tests to my app. I'm having trouble passing the tenant id (in my case it's int of 1). Error: Missing required parameter for [Route: filament.company.resources.seo-keywords.index] [URI: company/{tenant}/seo-keywords] ...
Solution:
In your beforeEach you probably want to set the tenant: ```php beforeEach(function(){...
No description

Parent and Child dropdown select

I want to have two select dropdowns, the second is dependent on the first but I can't get the second to respond
Solution:
hey, I have a working example, maybe it would be helpful?
No description

how to show a modal when press next on wizard step

i have a wizard with many steps and i want to add/remove steps based on user action , this action will be via a modal popup we show at first step when user press next button , when user accept or decline we perform certain actions based on the input any help is appreciated...

Filter content values does show

Filter content and values does not show when using filter visibility on tabs.
No description

Accessing the state of the repeater from inside the repeater

Hey all, I am currently working on a form that has a repeater somewhat like this: ``` Repeater::make('questions') ->label('Questions') ->translateLabel()...

Rule Builder labels being truncated

Hi, I am currently using the new Rule Builder feature in a form. ``` return $form ->schema([...
No description

Database notifications not working

I created an Exporter and it seems to be working fine (meaning I have the csv file on the public disk) but I never get the notification that the download is complete and a link to download like it is suppose to work. I do not have any errors in the logs or anywhere else, the job dispatches and is completed fine, I do have the notification in the database but never gets pulled into the notifications panel
Solution:
Not sure why the job uses App\Models\User though. I think it would be best to remove that again and solve the issue with App\User not working. What was the original error?

Accordion of Checkboxes in Forms

I need an accordion of checkboxes inside a form, how do i make a custom component for it? The docs are a bit confusing on regards to this.

Trying to have FileUpload works with my table

->How can I have fileupload to work with my DB structure ? Actually my images table is a polymorph table I have my component like that ```php Forms\Components\Fieldset::make('Featured Image')...
No description

Accessing repeater value from outside

Need help, how do I get the value of those inside the repeater and make the price update every time I made changes inside the repeater? This is my sample code: Repeater::make('products')...
Solution:
```php Repeater::make('products') ->live() ->schema([ TextInput::make('quantity')...
Next