Saeed Paracha
Saeed Paracha
FFilament
Created by Saeed Paracha on 1/6/2025 in #❓┊help
Filter Widget based on Active Tab Query
Found Solution:
protected function getHeaderWidgets(): array
{
$activeTabRecords = $this->modifyQueryWithActiveTab(CustomModel::query())->get();

return [
new MyCustomWidget::make(['records' => $activeTabRecords]),
];
}
protected function getHeaderWidgets(): array
{
$activeTabRecords = $this->modifyQueryWithActiveTab(CustomModel::query())->get();

return [
new MyCustomWidget::make(['records' => $activeTabRecords]),
];
}
and then in MyCustomWidget have: public $records property defined
4 replies