Skrypt
Blade Component - Button Group
This is weird.
Apart from including
@filamentStyles
after @livewireStyles
in the head and @filamentScripts
after @livewireScripts
in the body and using the filament preset in my tailwind config, there's nothing else I should do right?13 replies
Locale Prefix
Nah that doesn't work either. Then it probably just thinks that the
locale
is admin
.
We use https://github.com/codezero-be/laravel-localized-routes
on the front-facing part of the app and are trying to make it compatible with the filament panels and I'm having a hard time doing so. 😄
The package itself does a lot of magic to make it work it seems9 replies
Dynamic actions with modal
So I currently fixed it by rendering the modals manually using the Blade Component Library of Filament and then overriding each action by adding a alpineClickHandler to it, to call my manually created modals.
If anyone knows a better solution, I'd be happy to hear it 🙂
3 replies
Dynamic actions with modal
Basically currently I have a method which returns a dynamically created array of
I group them inside an Action Group and then render it using a for loop. They get rendered, but modals don't work anymore.
Actions
, it can be any amount of Actions.I group them inside an Action Group and then render it using a for loop. They get rendered, but modals don't work anymore.
3 replies
Action Modal on Simple Pages?
No worries, thanks anyways. 🙂
For other people who might stumble upon something similar, I think I finally found the issue, I had to pass a closure to the
action
method.
didn't work, but
did.
I'm pretty sure I tried that before already though, so I have no idea why it now works. 😄9 replies
Testing with Tenancy
Also, how would you go about testing a "Simple Resource" (where there is only a ManageRecords page)?
How would you test the CreateAction modals and test whether the record is created?
EDIT:
Okay, not sure if it's the best way, but this works (sorry example is in PHPUnit, I find Pest utterly confusing 😄 )
8 replies
Single login page for multiple panels
Thanks, I created and tried setting each login page for every panel to that page, which worked but resulted in different routes for each panel (such as /admin/login and /user/login), despite using the same class (so at least this solved the code duplication).
Turns out the best way so far was to disable all authorization pages (login, registration, etc) in every other panel except the default one and instead override them using closures,
so for example in the
AdminPanelProvider
and any other panel provider I would do:
...->login(fn() => redirect()->route('filament.core.auth.login'))
Thanks a lot guys 🙂5 replies