d2d.emegrendeles.hu/app/Filament/Resources/DeliverySchedules/DeliveryScheduleResource.php
2026-04-15 06:42:55 +02:00

69 lines
2.1 KiB
PHP

<?php
namespace App\Filament\Resources\DeliverySchedules;
use App\Filament\Resources\DeliverySchedules\Pages\CreateDeliverySchedule;
use App\Filament\Resources\DeliverySchedules\Pages\EditDeliverySchedule;
use App\Filament\Resources\DeliverySchedules\Pages\ListDeliverySchedules;
use App\Filament\Resources\DeliverySchedules\Schemas\DeliveryScheduleForm;
use App\Filament\Resources\DeliverySchedules\Tables\DeliverySchedulesTable;
use App\Models\DeliverySchedule;
use BackedEnum;
use Filament\Resources\Resource;
use Filament\Schemas\Schema;
use Filament\Support\Icons\Heroicon;
use Filament\Tables\Table;
use Illuminate\Database\Eloquent\Builder;
use Illuminate\Database\Eloquent\SoftDeletingScope;
class DeliveryScheduleResource extends Resource
{
protected static ?string $model = DeliverySchedule::class;
protected static string|BackedEnum|null $navigationIcon = 'heroicon-o-calendar-days';
protected static string|\UnitEnum|null $navigationGroup = 'Szállítási naptár';
protected static ?string $navigationLabel = 'Szállítási sablonok';
protected static ?string $modelLabel = 'Szállítási sablon';
protected static ?string $pluralLabel = 'Szállítási sablonok';
protected static ?string $breadcrumb = 'Szállítási sablonok';
public static function form(Schema $schema): Schema
{
return DeliveryScheduleForm::configure($schema);
}
public static function table(Table $table): Table
{
return DeliverySchedulesTable::configure($table);
}
public static function getRelations(): array
{
return [
//
];
}
public static function getPages(): array
{
return [
'index' => ListDeliverySchedules::route('/'),
'create' => CreateDeliverySchedule::route('/create'),
'edit' => EditDeliverySchedule::route('/{record}/edit'),
];
}
public static function getRecordRouteBindingEloquentQuery(): Builder
{
return parent::getRecordRouteBindingEloquentQuery()
->withoutGlobalScopes([
SoftDeletingScope::class,
]);
}
}