refactor: Rename 'Lokasi' to 'Lokus' and 'Sub Lokasi' to 'Sub Lokus' in Filament resource labels and titles.

This commit is contained in:
Yoga Pangestu 2026-01-27 21:11:59 +07:00
parent 221b301d89
commit d8cf50ce1f
6 changed files with 13 additions and 13 deletions

View File

@ -35,7 +35,7 @@ class LocationResource extends Resource
protected static string|BackedEnum|null $navigationIcon = Heroicon::MapPin;
protected static ?string $navigationLabel = 'Lokasi';
protected static ?string $navigationLabel = 'Lokus';
protected static ?int $navigationSort = 3;
@ -97,7 +97,7 @@ public static function table(Table $table): Table
])
->toolbarActions([
BulkActionGroup::make([
...DefaultBulkActions::make('Lokasi'),
...DefaultBulkActions::make('Lokus'),
]),
])
->emptyStateIcon(Heroicon::MapPin)

View File

@ -11,14 +11,14 @@ class ManageLocations extends ManageRecords
{
protected static string $resource = LocationResource::class;
protected static ?string $title = 'Lokasi';
protected static ?string $title = 'Lokus';
protected function getHeaderActions(): array
{
return [
CreateAction::make()
->label('Tambah')
->modalHeading('Tambah Lokasi')
->modalHeading('Tambah Lokus')
->modalSubmitActionLabel('Simpan')
->modalCancelActionLabel('Batal')
->extraModalFooterActions(fn (CreateAction $action): array => [

View File

@ -9,7 +9,7 @@
class ManageSubLocations extends ManageRecords
{
protected static ?string $title = 'Sub Lokasi';
protected static ?string $title = 'Sub Lokus';
protected static string $resource = SubLocationResource::class;
@ -18,7 +18,7 @@ protected function getHeaderActions(): array
return [
CreateAction::make()
->label('Tambah')
->modalHeading('Tambah Sub Lokasi')
->modalHeading('Tambah Sub Lokus')
->modalSubmitActionLabel('Simpan')
->modalCancelActionLabel('Batal')
->extraModalFooterActions(fn (CreateAction $action): array => [

View File

@ -37,7 +37,7 @@ class SubLocationResource extends Resource
protected static string|BackedEnum|null $navigationIcon = Heroicon::NumberedList;
protected static ?string $navigationLabel = 'Sub Lokasi';
protected static ?string $navigationLabel = 'Sub Lokus';
protected static ?int $navigationSort = 4;
@ -50,7 +50,7 @@ public static function form(Schema $schema): Schema
return $schema
->components([
Select::make('location_id')
->label('Lokasi')
->label('Lokus')
->options(Location::query()->pluck('name', 'id'))
->searchable()
->native(false)
@ -74,7 +74,7 @@ public static function table(Table $table): Table
return $table
->columns([
TextColumn::make('location.name')
->label('Lokasi')
->label('Lokus')
->searchable()
->sortable(),
@ -113,7 +113,7 @@ public static function table(Table $table): Table
])
->toolbarActions([
BulkActionGroup::make([
...DefaultBulkActions::make('Sub Lokasi'),
...DefaultBulkActions::make('Sub Lokus'),
]),
])
->emptyStateIcon(Heroicon::NumberedList)

View File

@ -31,7 +31,7 @@ public static function configure(Schema $schema): Schema
Grid::make(2)
->schema([
Select::make('location_id')
->label('Lokasi')
->label('Lokus')
->relationship('location', 'name')
->searchable()
->preload()
@ -43,7 +43,7 @@ public static function configure(Schema $schema): Schema
->autocomplete(false),
Select::make('sub_location_id')
->label('Sub Lokasi')
->label('Sub Lokus')
->relationship('subLocation', 'name', fn (Builder $query, Get $get): Builder => $query->where('location_id', $get('location_id')))
->searchable()
->preload()

View File

@ -41,7 +41,7 @@ public static function configure(Table $table): Table
->sortable(),
TextColumn::make('location.name')
->label('Lokasi')
->label('Lokus')
->searchable()
->sortable(),