The default behavior for the modelAdmin is to render a <select> element 
containing *every* instance of the model referred to by the FK.  

When this field refers to a model that has for example, 100,000 or more 
entries, this can have the affect of crashing a server, a browser, or at 
best making new users confused about why they cannot view the admin page 
for this instance as they will often experience a timeout.

I was thinking something like the following on admin.BaseModelAdmin might 
be helpful for people who would like to implement a different default 
behavior.

def get_raw_id_fields(self):

    """

    Hook for overriding default raw_id_fields behavior

    """

    return self.raw_id_fields

Anyone think this might a good idea?

-- 
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 http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/cccba1b1-6903-4cd4-ae77-7124fabbfb7b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to