diff --git a/extensions/Others/Onboarding/Admin/Resources/OnboardingResource.php b/extensions/Others/Onboarding/Admin/Resources/OnboardingResource.php index 5930d2cd2..2bc3ad454 100644 --- a/extensions/Others/Onboarding/Admin/Resources/OnboardingResource.php +++ b/extensions/Others/Onboarding/Admin/Resources/OnboardingResource.php @@ -36,8 +36,7 @@ class OnboardingResource extends Resource public static function form(Form $form): Form { return $form - ->columns(1) - ->components([ + ->schema([ TextInput::make('title') ->label('Title') ->required() @@ -85,8 +84,6 @@ class OnboardingResource extends Resource Select::make('page_route') ->label('Page to Guide To') - ->visible(fn (Get $get): bool => $get('is_guided')) - ->required(fn (Get $get): bool => $get('is_guided')) ->options([ 'dashboard' => 'Dashboard', 'services' => 'Services', @@ -100,8 +97,11 @@ class OnboardingResource extends Resource 'account.notifications' => 'Notifications', 'products' => 'Browse Products', ]) - ->helperText('Select which page the user should be guided to'), - ]); + ->helperText('Select which page the user should be guided to') + ->visible(fn (Get $get): bool => $get('is_guided')) + ->required(fn (Get $get): bool => $get('is_guided')), + ]) + ->columns(1); } public static function table(Table $table): Table diff --git a/extensions/Others/Onboarding/Onboarding.php b/extensions/Others/Onboarding/Onboarding.php index b84cc589c..fc6bbad62 100644 --- a/extensions/Others/Onboarding/Onboarding.php +++ b/extensions/Others/Onboarding/Onboarding.php @@ -62,13 +62,6 @@ class Onboarding extends Extension public function boot() { - if (app()->runningInConsole() === false) { - \Filament\Facades\Filament::getCurrentPanel()?->resources([ - \Paymenter\Extensions\Others\Onboarding\Admin\Resources\OnboardingResource::class, - ]); - } - - app('view')->addNamespace('onboarding', __DIR__ . '/resources/views'); diff --git a/extensions/Others/Onboarding/resources/views/modal.blade.php b/extensions/Others/Onboarding/resources/views/modal.blade.php index 995547767..25e3c82f3 100644 --- a/extensions/Others/Onboarding/resources/views/modal.blade.php +++ b/extensions/Others/Onboarding/resources/views/modal.blade.php @@ -1,3 +1,4 @@ +@php use Illuminate\Support\Facades\Storage; @endphp