refactor: Adjust Filament navigation sort orders for various resources, pages, and plugins.

This commit is contained in:
Yoga Pangestu 2026-03-12 10:12:23 +07:00
parent f6681cc5aa
commit ae627b076e
8 changed files with 13 additions and 9 deletions

View File

@ -37,7 +37,7 @@ class Index extends Page implements HasActions, HasForms
protected static ?string $title = 'Jadwal Kuliah';
protected static ?int $navigationSort = 1;
protected static ?int $navigationSort = 5;
protected static ?string $recordTitleAttribute = 'day_of_week';

View File

@ -39,7 +39,7 @@ class Index extends Page implements HasActions, HasForms
protected static ?string $title = 'Kelompok Belajar';
protected static ?int $navigationSort = 10;
protected static ?int $navigationSort = 20;
protected static ?string $slug = 'learning/study-groups';

View File

@ -36,7 +36,7 @@ public static function getPagePermission(): string
return 'View:ManageSettings';
}
protected static ?int $navigationSort = 10;
protected static ?int $navigationSort = 5;
protected static string $settings = GeneralSettings::class;

View File

@ -27,7 +27,7 @@ class AssignmentResource extends Resource
protected static ?string $navigationLabel = 'Tugas';
protected static ?int $navigationSort = 5;
protected static ?int $navigationSort = 15;
protected static ?string $recordTitleAttribute = 'title';

View File

@ -47,7 +47,7 @@ class MaterialResource extends Resource
protected static ?string $navigationLabel = 'Materi';
protected static ?int $navigationSort = 3;
protected static ?int $navigationSort = 10;
protected static ?string $recordTitleAttribute = 'title';

View File

@ -37,7 +37,7 @@ class CourseResource extends Resource
protected static ?string $navigationLabel = 'Mata Kuliah';
protected static ?int $navigationSort = 20;
protected static ?int $navigationSort = 15;
protected static ?string $recordTitleAttribute = 'name';

View File

@ -25,7 +25,7 @@ class StudentResource extends Resource
protected static ?string $navigationLabel = 'Mahasiswa';
protected static ?int $navigationSort = 1;
protected static ?int $navigationSort = 5;
protected static ?string $recordTitleAttribute = 'full_name';

View File

@ -69,7 +69,9 @@ public function panel(Panel $panel): Panel
Authenticate::class,
])
->plugins([
FilamentShieldPlugin::make(),
FilamentShieldPlugin::make()
->navigationSort(5),
AuthUIEnhancerPlugin::make()
->formPanelPosition('left')
->formPanelWidth('40%')
@ -93,7 +95,8 @@ public function panel(Panel $panel): Panel
->navigationLabel('Log')
->navigationUrl('/system/logs')
->pollingTime(null)
->authorize(fn () => auth()->user()->can('View:LogTable')),
->authorize(fn () => auth()->user()->can('View:LogTable'))
->navigationSort(10),
MobileBottomNav::make()
->items([
@ -131,6 +134,7 @@ public function panel(Panel $panel): Panel
'Pembelajaran',
'Informasi',
'Sistem',
'Pelindung',
]);
}
}