mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-20 00:30:50 +08:00
nexus_config can access filament
This commit is contained in:
@@ -104,8 +104,7 @@ class User extends Authenticatable implements FilamentUser, HasName
|
||||
|
||||
public function canAccessFilament(): bool
|
||||
{
|
||||
return true;
|
||||
// return str_ends_with($this->email, '@yourdomain.com') && $this->hasVerifiedEmail();
|
||||
return $this->class >= self::CLASS_ADMINISTRATOR;
|
||||
}
|
||||
|
||||
public function getFilamentName(): string
|
||||
|
||||
@@ -265,6 +265,7 @@ function nexus_config($key, $default = null)
|
||||
$files = [
|
||||
ROOT_PATH . 'config/nexus.php',
|
||||
ROOT_PATH . 'config/emoji.php',
|
||||
ROOT_PATH . 'config/filament.php',
|
||||
];
|
||||
foreach ($files as $file) {
|
||||
$basename = basename($file);
|
||||
|
||||
Reference in New Issue
Block a user