Filament page filter
I have this code where I have tried to pass date filter in my filament page. I made one similar type of report few months ago which works with this similar approad but this one is not working. Even when I pass the date filter the data is not changing in the view but the date is passing through.
https://gist.github.com/Namrata199/b913be06177c0b1317d334180e3826ce
Gist
Filament Page Data not changing
Filament Page Data not changing. GitHub Gist: instantly share code, notes, and snippets.
Solution:Jump to solution
https://filamentphp.com/docs/3.x/tables/adding-a-table-to-a-livewire-component#adding-the-table
```php
public function table(Table $table): Table
{...
22 Replies
Livewire
Lifecycle Hooks | Livewire
A full-stack framework for Laravel that takes the pain out of building dynamic UIs.
I used mount but it did not work. The problem is the data doesnot change even when I apply the date filter
?
where do i do this ?
this gives error
are you using Filament v3?
yes
Solution
Thanks a lot this solved the data issue but since I am returning a collection,
here the table part crashes.
so there is no way ti get the data I want ? with my query ?
If it returns an Eloquent Builder, it will work
I changed it to retrun this
try
product_id as id
in the selectgives this
share the whole code
try to share the whole code in gist please
https://gist.github.com/Namrata199/b913be06177c0b1317d334180e3826ce this is the updated gist with my latest code
Gist
Filament Page Data not changing
Filament Page Data not changing. GitHub Gist: instantly share code, notes, and snippets.
try
private $apiData = null;
This worked !! thanks a lot !! Really appreciate this !!