I solved this by sorting the tuple of tuples outside of the add/create
custom manipulators, then using that sorted list instead of
ColorAccount.COLORS:

   col_list = list(ColorAccount.COLORS)
   col_list.sort(lambda x, y: cmp(x[1], y[1]))
   col_tuple = tuple(col_list)

And then:

   forms.SelectField(field_name="fav_color",choices=col_tuple)

I guess this was more of a python issue.


--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to