Hi,

Check out raw_id_fields if you haven't.

Either on ArticleAdmin:
raw_id_fields = ['categories']

Or as an inline:
class CategoryInline(models.TabularInline):
    model = Article.categories.through
    extra = 0
    raw_id_fields = ['category']

Collin

On Wednesday, December 10, 2014 2:32:20 AM UTC-5, James Y wrote:
>
> I have a Category model that is m2m with an Article model and need to make 
> categories selectable in my article admin. So I'm using a filter_horizontal 
> and the problem is that I have thousands of categories and do not want to 
> load them all into the left hand side (lhs) of filter_horizontal.
>
> Is there a way to limit the lhs to just a search functionality instead of 
> a category browse?
>
> Is there another widget I should use just for searching categories to make 
> m2m relationships?
>
> Thanks
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/3b9ccd14-7744-4a66-a22f-cb70132e683c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to