python-adminui icon indicating copy to clipboard operation
python-adminui copied to clipboard

Uploaded file information stays in the form data dictionary even after a file is removed using the upload component's delete icon

Open jwag59 opened this issue 3 years ago • 0 comments

When using an Upload component in a Modal form, if the user uses the small delete icon next to the uploaded file to remove the file from the uploaded file list, when the form is submitted the upload file information still exists in the form data passed to the on_submit function.

This is problematic for my use case as the user can either select a file from a SelectBox component or upload a new file using the Upload component. If both are specified it is difficult to decide which one should be used. And in the case they upload a file but then decide they don't want to use that file and delete it then the file information should also be erased from the form data dictionary, indicating no file is available as yet.

jwag59 avatar Jun 14 '22 14:06 jwag59