Closed mercury64 closed 3 months ago
Are you overriding the observer? Curator doesn't actually try to store originalFilename and it's only used when replacing a file where the observer removes it from the form data before saving the record.
No I am not overriding anything, zero custom code, fresh install of Laravel, Filament and Curator.
I've done some debugging. When uploading an image, the following happens:
Awcodes\Curator\Components\Forms\Uploader.php, function saveUploadedFiles(), at the following line:
$this->storeFileName($storedFile['path'], $file->getClientOriginalName());
Then in storeFileName function from Filament\Forms\Components\BaseFileUpload $statePath = $this->fileNamesStatePath;
where fileNamesStatePath is orignalFilename.
I can only deep dive into the code so far before I start getting lost.
It maybe some conflict with an update with Filament.
I've reinstalled three times, same issue.
This occurs from the Media-> New Media -> Create.
This does not happen from the CurratorPicker as a block on my page, Add Media -> Add Files.
Ok. I will look into it as soon as I can. Thank you.
I can't seem to replicate this. New media is working correctly for me.
Can you give me a reproduction repo to look at.
If you are switching from spatie-media-library, make sure to drop the media table.
Filament Version
v3.2.71
Plugin Version
v3.5.6
PHP Version
PHP v8.3.4
Problem description
originalFilename missing from database schema during install.
SQL error on first media upload after fresh install.
Expected behavior
All database columns should be created during install.
This needs to be added
$table->string('originalFilename');
Steps to reproduce
Install new and add one image.
Reproduction repository
No response
Relevant log output