attrs={'multiple': True}
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.
--
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-develop...@googlegroups.com.
To post to this group, send email to django-d...@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.
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.Whilst it's not the normal way of deprecating things in Django, I'm not against it. Would we ever block attrs={'multiple':True} though? Afaiu there would still be use cases for setting that attribute and doing custom multiple file handling. Maybe even a warning wouldn't be necessary.
Hi Joe,
Just an idea:
Why not just use another keyword argument, like "files_number",
"count", "max_files" (along maybe with a "min_files"), or
something like, with a default of 1 (to match current behaviour
with a single file), and an allowed value of 0 for infinite?
If you allow multiple files upload at once, chances are that there will be many use cases for limiting the number of uploads to a specific range/value.
Not sure about the form's implementation, though.
- Brice
You received this message because you are subscribed to a topic in the Google Groups "Django developers (Contributions to Django itself)" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/django-developers/U9XNvd4Q2vY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to django-develop...@googlegroups.com.
To post to this group, send email to django-d...@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/73de1c91-dc5c-9b72-10fc-af37e36c50a2%40brice.xyz.