Thanks a lot, Daniel! That did the trick.


On Feb 20, 4:55 am, Daniel Roseman <roseman.dan...@googlemail.com>
wrote:
> On Feb 20, 4:32 am, Eric <eric.sodo...@gmail.com> wrote:
>
>
>
> > Hi, I have an admin filter that filters all entries that have a
> > particular foreign key. Specifically, this foreign key is a "Code"
> > object that contains a "Code #" and a "Description".
>
> > In the admin filter display, it shows all the codes I can filter by,
> > but they are all out of order, i.e.
>
> > Filter by code:
> >     * All
> >     * 3130
> >     * 3340
> >     * 3410
> >     * 5361
> >     * 3370
> >     * 9760
> >     * 1570
> >     * 1090
>
> > This is proving to be a pain for people to navigate. What I'd like is
> > to have this filter list the codes in increasing order. Any
> > suggestions?
>
> > Thanks much!
>
> Define an 'ordering' value in the Meta class for the model your FK is
> pointing to.http://docs.djangoproject.com/en/dev/ref/models/options/#ordering
> --
> DR.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to