34 lines
930 B
PHP
34 lines
930 B
PHP
<?php
|
|
namespace App\Filament\Pages\Strumenti;
|
|
|
|
use App\Models\User;
|
|
use BackedEnum;
|
|
use Filament\Pages\Page;
|
|
use Illuminate\Support\Facades\Auth;
|
|
use UnitEnum;
|
|
|
|
class PassaggiDiConsegne extends Page
|
|
{
|
|
protected static ?string $navigationLabel = 'Passaggi di consegne';
|
|
|
|
protected static ?string $title = 'Passaggi di consegne';
|
|
|
|
protected static BackedEnum|string|null $navigationIcon = 'heroicon-o-archive-box-arrow-down';
|
|
|
|
protected static UnitEnum|string|null $navigationGroup = 'Strumenti';
|
|
|
|
protected static ?int $navigationSort = 50;
|
|
|
|
protected static ?string $slug = 'strumenti/passaggi-di-consegne';
|
|
|
|
protected string $view = 'filament.pages.strumenti.passaggi-di-consegne';
|
|
|
|
public static function canAccess(): bool
|
|
{
|
|
$user = Auth::user();
|
|
|
|
return $user instanceof User
|
|
&& $user->hasAnyRole(['super-admin', 'admin', 'amministratore', 'collaboratore']);
|
|
}
|
|
}
|