Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to control the ActivityResource navigation sort and if scoped to tenant #117

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions config/filament-logger.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,15 @@
'date_format' => 'd/m/Y',

'activity_resource' => \Z3d0X\FilamentLogger\Resources\ActivityResource::class,
'scoped_to_tenant' => true,
'navigation_sort' => null,

'resources' => [
'enabled' => true,
'log_name' => 'Resource',
'logger' => \Z3d0X\FilamentLogger\Loggers\ResourceLogger::class,
'color' => 'success',

'exclude' => [
//App\Filament\Resources\UserResource::class,
],
Expand Down
12 changes: 12 additions & 0 deletions src/Resources/ActivityResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -331,4 +331,16 @@ public static function getNavigationIcon(): string
{
return __('filament-logger::filament-logger.nav.log.icon');
}

public static function isScopedToTenant(): bool
{
return config('filament-logger.scoped_to_tenant', true);
}

public static function getNavigationSort(): ?int
{
return config('filament-logger.navigation_sort', null);
}


}