nexus_config can access filament

This commit is contained in:
xiaomlove
2022-06-27 17:33:40 +08:00
parent 30261680a8
commit ae351bfdaf
2 changed files with 2 additions and 2 deletions

View File

@@ -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

View File

@@ -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);