Great! A cleaner solution. Thanks! Is there any effort underway for making overriding default widgets simpler? I think that's really needed (especially for beginner like me).
2B On Jun 8, 1:20 am, Nathaniel Whiteinge <[EMAIL PROTECTED]> wrote: > On Jun 7, 4:18 pm, Berco Beute <[EMAIL PROTECTED]> wrote: > > > Quite a lot of work for something so simple > > I agree that overriding default widgets is currently too much work. > But here's a slightly shorter version that works in exactly the same > way as your example:: > > class SomeForm(forms.ModelForm): > class Meta: > model = SomeModel > > car = forms.ModelChoiceField(Car.objects.all(), > empty_label=None) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected] 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 -~----------~----~----~----~------~----~------~--~---

