mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-24 12:07:23 +08:00
filament setting apge
This commit is contained in:
@@ -30,6 +30,11 @@ class ExamUserResource extends Resource
|
||||
return __('admin.sidebar.exam_users');
|
||||
}
|
||||
|
||||
public static function getBreadcrumb(): string
|
||||
{
|
||||
return self::getNavigationLabel();
|
||||
}
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
return $form
|
||||
|
||||
@@ -29,6 +29,11 @@ class HitAndRunResource extends Resource
|
||||
return __('admin.sidebar.hit_and_runs');
|
||||
}
|
||||
|
||||
public static function getBreadcrumb(): string
|
||||
{
|
||||
return self::getNavigationLabel();
|
||||
}
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
return $form
|
||||
|
||||
@@ -28,6 +28,10 @@ class UserResource extends Resource
|
||||
return __('admin.sidebar.users_list');
|
||||
}
|
||||
|
||||
public static function getBreadcrumb(): string
|
||||
{
|
||||
return self::getNavigationLabel();
|
||||
}
|
||||
|
||||
public static function form(Form $form): Form
|
||||
{
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
namespace App\Filament\Resources\User\UserResource\Pages;
|
||||
|
||||
use App\Filament\Resources\User\UserResource;
|
||||
use App\Models\User;
|
||||
use Filament\Resources\Pages\Page;
|
||||
|
||||
class UserProfile extends Page
|
||||
@@ -10,4 +11,19 @@ class UserProfile extends Page
|
||||
protected static string $resource = UserResource::class;
|
||||
|
||||
protected static string $view = 'filament.resources.user.user-resource.pages.user-profile';
|
||||
|
||||
protected ?User $user;
|
||||
|
||||
|
||||
public function mount($record)
|
||||
{
|
||||
$this->user = User::query()->with(['inviter'])->findOrFail($record);
|
||||
}
|
||||
|
||||
protected function getViewData(): array
|
||||
{
|
||||
return [
|
||||
'user' => $this->user,
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user