Add solutions image upload field and update settings: introduce a file upload component for solutions images in ManageSolutions, add solutions_image property to SolutionSettings, and update related database migrations and views to support dynamic image display.
This commit is contained in:
1 parent
bae4204d44
commit
2d1c7ea4f9
10 files changed
+58
-76
No files matched your search
@@ -3,6 +3,7 @@
|
||||
namespace App\Filament\Pages;
|
||||
|
||||
use App\Settings\SolutionSettings;
|
||||
use Filament\Forms\Components\FileUpload;
|
||||
use Filament\Forms\Components\Grid;
|
||||
use Filament\Forms\Components\Repeater;
|
||||
use Filament\Forms\Components\Section;
|
||||
@@ -33,6 +34,11 @@ public function form(Form $form): Form
|
||||
->label('Header')
|
||||
->required()
|
||||
->maxLength(255),
|
||||
FileUpload::make('solutions_image')
|
||||
->label('Image')
|
||||
->image()
|
||||
->directory('solutions')
|
||||
->required(),
|
||||
Grid::make()->schema([
|
||||
TextInput::make('solutions_button_text')
|
||||
->label('Button Text')
|
||||
|
||||
@@ -14,6 +14,8 @@ class SolutionSettings extends Settings
|
||||
|
||||
public string $solutions_button_url;
|
||||
|
||||
public ?string $solutions_image;
|
||||
|
||||
public array $solution_items;
|
||||
|
||||
public static function group(): string
|
||||
|
||||
Reference in new issue
Block a user