#4907: MultipleChoiceField cleaned_data returns last choice
------------------------------------------------+---------------------------
Reporter: [EMAIL PROTECTED] | Owner: adrian
Status: reopened | Component:
django.newforms
Version: SVN | Resolution:
Keywords: MultipleChoiceField cleaned_data | Stage:
Unreviewed
Has_patch: 0 | Needs_docs: 0
Needs_tests: 0 | Needs_better_patch: 0
------------------------------------------------+---------------------------
Changes (by Wang Chun <[EMAIL PROTECTED]>):
* status: closed => reopened
* resolution: worksforme =>
Comment:
sorry about the unclear description above.
Create models like:
{{{
from django.db import models
class Publication(models.Model):
title = models.CharField(max_length=20)
class Admin:
pass
def __unicode__(self):
return self.title
class Person(models.Model):
name = models.CharField(max_length=20)
class Admin:
pass
def __unicode__(self):
return self.name
class Comm(models.Model):
title = models.CharField(max_length=20)
pubs = models.ForeignKey(Publication)
attendees = models.ManyToManyField(Person)
class Admin:
pass
def __unicode__(self):
return self.title
}}}
As in attached image http://code.djangoproject.com/attachment/ticket/4907
/Screenshot-
Add%20comm%20%7C%20Django%20site%20admin%20-%20Mozilla%20Firefox-1.png : I
created 13 person objects in django admin, when I was trying to add a comm
with initial parameter "attendees=1&attendees=2", only the attendee
"person1" (id=2) was selected.
As in attached image http://code.djangoproject.com/attachment/ticket/4907
/Screenshot-
Add%20comm%20%7C%20Django%20site%20admin%20-%20Mozilla%20Firefox.png :
When I was trying to set the parameter to "attendees=12", person11 (id=12)
should be selected, but here in the test, person0 (id=1) and person1
(id=2) was selected. There is no way to select person11 with the
"attendees" URL query string.
--
Ticket URL: <http://code.djangoproject.com/ticket/4907#comment:4>
Django Code <http://code.djangoproject.com/>
The web framework for perfectionists with deadlines
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" 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-updates?hl=en
-~----------~----~----~----~------~----~------~--~---