acroninja
Export download logs out with other auth guards and tenants
This route:-
Seems to only apply to the main admin panel. If i try to download an export on a tenant domain I get redirected to admin.
I've tried adding a manual route like this but no luck. Can anyone help??
8 replies
Export fails when query has with relation
This serialize facade used in the exporter errors ungracefully if there are any ->with('relation') on the query. Taken a while to figure out what was happening.
It references this package and there are others with similar problems.
https://github.com/AnourValar/eloquent-serialize/issues?q=relation
https://github.com/AnourValar/eloquent-serialize/issues?q=relation
3 replies
Select Filter with nested relation won't filter
If we use a direct relationship the select filter works
Nested relations provide the correct dropdown options but does not filter the results
If try to add a query or ->modifyQueryUsing $data array is never populated.
Also tried to create direct relation on the model like this but throws an error
5 replies
Duplicate navigation items when overriding a package resource.
In my package i've made shouldRegisterNavigation a config option like this
Which hides menu item when set to false.
We've then created a local override for this file due to client customisation requirements and set shoudRegisterNavigation to true
But for some reason this duplicates the menu item in the cluster.
I've tried setting shouldRegisterNavigation to false and manually registering the nav item in the panel config but it looks like clusters aren't yet supported in
so I it won't show in the correct menu. Anyone else had this issue or can suggest a solution?
Thanks
4 replies
Checkbox list from relation only orders by title? Solved just use modifyQueryUsing
We need to order a checkbox list by ID so that the option "Other" always comes last as it is when ordered by id.
I'm going to create an override of the CheckboxList class relationship function but wondering if others have this issue and maybe it would be nice to have an orderBy option for the list
4 replies
How to change the session cookie name between panels?
We have an app with 3 different admin panels each with their own auth guard.
This is causing a problem if you login to 2 different panels on the same browser. It's fine if you clear cookies or go incognito.
I just need the session cookie to be named differently between the panels - can anyone suggest a method to achieve this?
I just need the session cookie to be named differently between the panels - can anyone suggest a method to achieve this?
5 replies
Unable to download export with polymorphic user and custom guard
Our export migration uses the
$table->morphs('user');
and in a service provider i have Export::polymorphicUserRelationship();
But accessing the download url redirects me to /admin/login
even though I am already logged in.
The download route uses the 'filament.actions' middleware group:-
Which is created in ActionsServiceProvider:-
(not used by anything else) but I need the 'auth:admin
middleware.
I did add $this->app->bind(Authenticatable::class, Admin::class);
also to the service provider but doesn't help, without the correct auth guard we're not going to get that far.
Should i just override the ActionsServiceProvider or is there a better filament way?
Thx for any tips3 replies
Bug with sidebar notifications not marked as read but deleted
When you dismiss a sidebar notification they are deleted rather than marked as read. Not sure this should be the expected behaviour. Haven't dug into the code yet, does anyone know if this is an easy fix? Notification log is a useful audit history feature
2 replies
Where to put @livewire('database-notifications')
The docs say put this in your blade layout.
https://filamentphp.com/docs/3.x/notifications/database-notifications
Do I need to create an override for views/components/layout/simple.blade.php and add it here or is there a better way to do it?
14 replies
Repeater relations meta data not merged with existing and overwrites other meta data.
I have 2 forms, each have different fields that both save in the SAME meta json column on the relation.
form1: meta.passport.number + meta.passport.expiry
form2: meta.nationality + meta.date_of_birth.
The data from each form is saved but does not merge with existing meta. I've tried using the
Have tried getting existing data from $this->record and merging with $this->data but the relationship save happens before these functions are called. In
handleRecordUpdate
and mutateFormDataBeforeSave
on the page but $data
is empty.Have tried getting existing data from $this->record and merging with $this->data but the relationship save happens before these functions are called. In
src/Components/Repeater.php
the $this->saveRelationshipsUsing(
has the correct data all merged in $state but then it's lost a bit further down. Is this expected behavior?
Perhaps a workaround solution is to create a separate json column for each form - but I have 12 forms each with some different meta. Feels a bit clunky to make separate columns. Any advice gratefully received. Ta.4 replies
Form wizard loses values from previous steps after page reload
Maybe this is the correct action after page refresh, but with the step url parameter I end up halfway through the wizard but without previous steps having any values. Should I check for this and redirect back to step 1?
3 replies
Is it possible to have a panel that is public without authentication?
Currently if I remove auth middleware the Filament\FilamentManager::getUserAvatarUrl() can't find an auth user so throws an error.
Don't know if it's worth trying to make this work or not?
14 replies
How to add a repeating infolist to show all records from a resource?
I can see how to define an infolist but would like to give it a datasource of Model::all() to show all records as cards.
I'd like to add this to a custom page or if it's easier I can create a new resource.
Effectively I need a list page but in a grid format instead of a table. Any suggestions gratefully received, can't tell from the docs if I need to create a custom livewire component or if I can add it to a resource page?
Effectively I need a list page but in a grid format instead of a table. Any suggestions gratefully received, can't tell from the docs if I need to create a custom livewire component or if I can add it to a resource page?
4 replies