Trying to have FileUpload works with my table

->How can I have fileupload to work with my DB structure ? Actually my images table is a polymorph table

I have my component like that
Forms\Components\Fieldset::make('Featured Image')
                    ->relationship('featuredImage')
                    ->schema([
                        Forms\Components\FileUpload::make('file_name')
                            ->disk('s3-public')
                            ->directory('image/resource/1/1/4/114/')
                            ->previewable(true)
                            ->preserveFilenames()
                            ->visibility('public')
                            ->image()
                    ]),


->directory seems to doesn't work too. If I Put the image at the root of my disk, the image is displayed; but not if my image is in image/resource/1/1/4/114/

What do I need to change the saving process and use my own column ?
image.png
Was this page helpful?