Mike Scott
Mike Scott
FFilament
Created by Mike Scott on 5/25/2024 in #❓┊help
Importer fails rows with blank email fields when the email rule is applied to the column
Figured it out immediately after posting 😆 The solution is to add a nullable rule to the column along with the 'email' rule:
ImportColumn::make('email')
->rules(['nullable', 'email']),
ImportColumn::make('email')
->rules(['nullable', 'email']),
4 replies
FFilament
Created by Mike Scott on 5/20/2024 in #❓┊help
SOLVED: Potential Security Issue - Filament isn't exposing model attributes. It was a false alarm.
I had a look at the Chrome network tab and don't see anything untoward. I had a feeling I was missing something and wanted to discuss it here. Thanks.
9 replies
FFilament
Created by Mike Scott on 5/20/2024 in #❓┊help
SOLVED: Potential Security Issue - Filament isn't exposing model attributes. It was a false alarm.
I'm aware that DebugBar is a debugging tool. I've not used Livewire before and I'm unclear what the Livewire tab in DebugBar is showing. At first glance it looks like it's collecting and displaying the Livewire traffic being sent to the browser. So I would like to be sure that what it's showing is NOT what is being sent to the browser by Filament or Livewire.
9 replies
FFilament
Created by Mike Scott on 5/20/2024 in #❓┊help
SOLVED: Potential Security Issue - Filament isn't exposing model attributes. It was a false alarm.
Thanks. I'm aware of the security policy but I wanted to discuss it here first before raising it with Dan as I wasn't sure if there was something I was missing.
9 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
Thank you for this. I can now see that it's not a trivial task, that out of the box Filament simply doesn't support multi-level menus. So now I'll look for another way to lay out my app.
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
Thanks for the screenshot, apparently showing it's possible. But it'll take more than some CSS. No-one can tell me simply how to add a group to a group.
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
That's exactly what we've been discussing and I've been trying. Even building the navigation from scratch as it says in the docs, there's no way that I can see to add a group to a group. That's the piece I'm missing. What is the function that you call to add a group to a group?
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
Can anyone confirm if it's even possible to have menu groups inside groups???
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
I can easily create a single level of nesting, with items within a top-level group. But as I said at the start, I want to go deeper and add a group inside another group
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
I don't want to add items to that group, I want to add other groups and groups aren't items.
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
Yes, I can add a group as a name and it creates a top-level menu. But how do I add another group to that group?
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
I can add navigation items in Filament::registerNavigationItems() no problem. But I can't add groups.
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
If I add that code where exactly?
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
And trying to add NavigationGroup::make() to Filament::registerNavigationItems() doesn't work either, since NavigationGroup isn't a NavigationItem and you get: Filament\FilamentManager::Filament{closure}(): Argument #1 ($item) must be of type Filament\Navigation\NavigationItem, Filament\Navigation\NavigationGroup given
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
Yes, this is in AppServiceProvider::boot(). Removing the registerNavigationGroups() wrapper doesn't work either:
public function boot(): void
{
Filament::serving(function () {
NavigationGroup::make('Top Level')->items([
NavigationGroup::make('Sub Level')->items([
NavigationItem::make('Google')
->url('https://google.com')
])
]);
});
}
public function boot(): void
{
Filament::serving(function () {
NavigationGroup::make('Top Level')->items([
NavigationGroup::make('Sub Level')->items([
NavigationItem::make('Google')
->url('https://google.com')
])
]);
});
}
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
I've no idea. No menu appears.
28 replies
FFilament
Created by Mike Scott on 7/11/2023 in #❓┊help
Multi-level Hierarchical Navigation Groups
Yes, I realised it had to be done manually but I've tried it various ways in my AppServiceProvider and couldn't get it to work. I can't see how to add a group to a group. For example, I tried this but no menu appears:
public function boot(): void
{
Filament::serving(function() {
Filament::registerNavigationGroups([
NavigationGroup::make('Top Level')->items([
NavigationGroup::make('Sub Level')->items([
NavigationItem::make('Google')
->url('https://google.com')
])
])
]);
});
}
public function boot(): void
{
Filament::serving(function() {
Filament::registerNavigationGroups([
NavigationGroup::make('Top Level')->items([
NavigationGroup::make('Sub Level')->items([
NavigationItem::make('Google')
->url('https://google.com')
])
])
]);
});
}
28 replies
FFilament
Created by Mike Scott on 6/30/2023 in #❓┊help
How to use a Checkbox to edit fields in a related model
Aha I just noticed you're suggesting a group relationship. I was confusing it with the CheckboxList relationship. I'll give it a try, thanks!
6 replies
FFilament
Created by Mike Scott on 6/30/2023 in #❓┊help
How to use a Checkbox to edit fields in a related model
Unfortunately that doesn't work, since it's a has-one relationship and the one record has many fields which need a checkbox for each field. The relationship method works only when there's a one-to-many relationship and each related record has a single value that gets a checkbox. In my example, feature_field is only one of the boolean fields in the related record. It has about 20 boolean fields.
6 replies
FFilament
Created by Mike Scott on 6/15/2023 in #❓┊help
How to access a route parameter in Livewire pagination request?
Shoulda thought of that 😄 Thanks Dennis!
6 replies