Oben im Seitenmenue waehlt man die Wohnung; Listen, neue Eintraege, Belegungsplan und Preise & Angebote folgen ihr. Ein geoeffneter Eintrag einer anderen Wohnung schaltet auf diese um. Galerie und Ersatz-Titelbild der Website zeigen nur Fotos der Wohnung des Bausteins und Fotos ohne Wohnung. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
62 lines
1.7 KiB
PHP
62 lines
1.7 KiB
PHP
<?php
|
|
|
|
namespace App\Filament\Resources\Amenities;
|
|
|
|
use App\Filament\Concerns\FollowsAdminMode;
|
|
use App\Filament\Concerns\SelectsRecordProperty;
|
|
use App\Filament\Resources\Amenities\Pages\CreateAmenity;
|
|
use App\Filament\Resources\Amenities\Pages\EditAmenity;
|
|
use App\Filament\Resources\Amenities\Pages\ListAmenities;
|
|
use App\Filament\Resources\Amenities\Schemas\AmenityForm;
|
|
use App\Filament\Resources\Amenities\Tables\AmenitiesTable;
|
|
use App\Models\Amenity;
|
|
use BackedEnum;
|
|
use Filament\Resources\Resource;
|
|
use Filament\Schemas\Schema;
|
|
use Filament\Support\Icons\Heroicon;
|
|
use Filament\Tables\Table;
|
|
use UnitEnum;
|
|
|
|
class AmenityResource extends Resource
|
|
{
|
|
use FollowsAdminMode, SelectsRecordProperty;
|
|
|
|
protected static ?string $model = Amenity::class;
|
|
|
|
protected static string|BackedEnum|null $navigationIcon = Heroicon::OutlinedListBullet;
|
|
|
|
protected static string|UnitEnum|null $navigationGroup = 'Webseite';
|
|
|
|
protected static ?string $modelLabel = 'Ausstattungsmerkmal';
|
|
|
|
protected static ?string $pluralModelLabel = 'Ausstattung';
|
|
|
|
protected static ?int $navigationSort = 4;
|
|
|
|
public static function form(Schema $schema): Schema
|
|
{
|
|
return AmenityForm::configure($schema);
|
|
}
|
|
|
|
public static function table(Table $table): Table
|
|
{
|
|
return AmenitiesTable::configure($table);
|
|
}
|
|
|
|
public static function getRelations(): array
|
|
{
|
|
return [
|
|
//
|
|
];
|
|
}
|
|
|
|
public static function getPages(): array
|
|
{
|
|
return [
|
|
'index' => ListAmenities::route('/'),
|
|
'create' => CreateAmenity::route('/create'),
|
|
'edit' => EditAmenity::route('/{record}/edit'),
|
|
];
|
|
}
|
|
}
|