ModelMultipleChoiceField doesn't respect to_field_name in validation.
I believe these should be consistent,
Change History
(9)
Triage Stage: |
Unreviewed → Design decision needed
|
Component: |
Uncategorized → Database layer (models, ORM)
|
Component: |
Database layer (models, ORM) → Forms
|
Keywords: |
modelmultiplechoicefield to_field_name added
|
milestone: |
→ 1.3
|
Owner: |
changed from nobody to Gregor Müllegger
|
Status: |
new → assigned
|
Summary: |
ModelMultipleChoiceField doesn't accept to_field_name whereas ModelChoiceField does → ModelMultipleChoiceField doesn't respect to_field_name in validation.
|
Triage Stage: |
Design decision needed → Ready for checkin
|
Resolution: |
→ fixed
|
Status: |
assigned → closed
|
This ticket is still valid. The
to_field_name
argument was already added to the ModelMultipleChoiceField however it ignores the argument for validation and expects primary keys. I will attach a patch for the current trunk.You can find the patch also in this github fork/branch: https://github.com/gregmuellegger/django/tree/issue9161