each user has different widget
i would like to show on dashboard the widgets of that user
Auth::user()->widgets() ....
9 Replies
I think this can be done with a custom dashboard :
https://filamentphp.com/docs/2.x/admin/dashboard/getting-started#customizing-the-dashboard-page
Filament
Getting started - Dashboard - Admin Panel - Filament
The elegant TALL stack admin panel for Laravel artisans.
can you show me an example please ?
what is Auth::user()->widgets()
i have created a custom dashboard ..
now i must pass a variable to "AdminWidgets"
that would be really very useful
what do you want filament to provide you with to achieve this
each user has several graphs, and I have to pass the question id to the widget
this is a found solution, even if I don't really like it and that it could be done better
in laravel\config\filament.php dashboard changed laravel\Modules\MyModule\Filament\Pages\Dashboard.php laravel\Modules\MyModule\Filament\Widgets\ChartsWidget.php
where I pass the parameters I need, in this case the ids his blade component created and called laravel\Modules\MyModule\Http\Livewire\QuestionChart.php I repeat, it is a solution, but it could be done better
in laravel\config\filament.php dashboard changed laravel\Modules\MyModule\Filament\Pages\Dashboard.php laravel\Modules\MyModule\Filament\Widgets\ChartsWidget.php
where I pass the parameters I need, in this case the ids his blade component created and called laravel\Modules\MyModule\Http\Livewire\QuestionChart.php I repeat, it is a solution, but it could be done better