Implement File upload support
The RequestBuilder object should handle file uploads as request arguments. A File object is needed to map the params and can be persisted. Reading of the file is done by a file reader extending abstract file reader which can be used to create objects from file data. Validation can be applied to the File object by writing the corresponding FileValidator.
Attached files are a quick try at csv file reading. Usage of property mapper should be rewritten.
Updated by Kevin Ulrich Moschallski almost 9 years ago
is there any update on backporting the FLOW3 ResourceManager to extbase?
Since the new property mapper brought us the FLOW3 type converter in extbase the backport should be possible now, right?
I currently trying to implement a clean way to upload a file or multiple files with a fluid form. I tried it with support of the fed extensions fileObjectStorage in conjunction of the Tx_Fed_Resource_File.
The problem is that Tx_Fed_Resource_File only handles already uploaded files, which leads the to the problem that i can't use it as property type in my model.
So i digger more into this and find this bug, after a quick look into the FLOW3 implementation i think this would be quite nice for extbase.
The biggest problems i think will be:
- Support TCA upload folder instead of a global folder like in FLOW3
- First bring #34528 into master (this will be a breaking change, as all upload properties will change from string to array)
- As far i can see the upload then would take place before validation is passed, this could lead to garbage files
- Maybe FAL should be implemented (don't know much about this up to now)
I really looking forward to hear some opinions on this as i'm willing to implement this or help on it.
Updated by Helmut Hummel about 6 years ago
- Status changed from New to Accepted
- Complexity set to hard
Would be great, to have something like that implemented.
However, please be aware, that by providing this solution to a broader audience I learned that it is not optimal like this. The file reference converter should rather respect that it is at the same time a resource as it is a domain model (title, description) etc.
I had no time to implement this as an example yet and most likely will not have the time to do so for 7.1