Hi there!

I do need some feedback on the best public API to implement multi file 
support to Django forms.

Context:

Up until now Django forms do not support multi file upload. You will need 
to write your own view to handle the files as described here:
https://docs.djangoproject.com/en/2.1/topics/http/file-uploads/#uploading-multiple-files

Of course it is not too hard to implement actual multi file support as I 
have been showcasing here:
https://github.com/django/django/pull/9011/files

The question is now to best add support for multiple file uploads without 
wrecking backwards compatibility?

As Tim wisely mentioned, it might be confusing to add a `multiple` argument 
to the FileField while also having the 
attrs={'multiple': True}
still in the mix.

My suggestion would be to add the new keyword argument which enable the new 
behavior and keep the attr-thing as is.
I could add a warning if someone uses the "old" style. It is a bit 
suggestive though.

What do you think, mabe look at the documentation changes in the PR for 
more context.

Best
-Joe

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/e71675d3-be96-4189-b0c1-038774626284%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to