Star Burger wrote:
In the web app I'm currently working on users can upload multiple images - and can also delete them later on.
Is there a way to easily delete uploaded files in file-column? The deletion should affect the database and the file structure of course.
I didn't find any documentation for that...
I find the easiest way to do that is to have a main record that has_one or has_many images. Each image has an ID, parent_id and file_column field. Then, all you need to do is destroy any image record. I believe that takes care of the rest