Opened 17 years ago
Closed 17 years ago
#7182 closed (invalid)
Extra MultiWidget fields in Inline in Admin are validating when left blank
Change History (6)
comment:1 by , 17 years ago
comment:2 by , 17 years ago
Summary: | Extra fields in Inline in Admin are validating when left blank → Extra MultiWidget fields in Inline in Admin are validating when left blank |
---|
Extra fields as in the extra blank records which are displayed for TabularInline or StackedInline editing:
class TextRangeInline(admin.StackedInline): model = TextRange extra = 3 listdisplay = ('start', 'end',)
Start and End are MultiValueFields stored as Integers, and edited through a MultiWidget.
So I would imagine that the problem would net occur when the Inline contains no MultiWidget fields.
comment:3 by , 17 years ago
I can't reproduce the problem. Are start
and
end
required fields? If not then make sure you have have marked them as not being required. I am beginning to wonder if the bug fix has uncovered a problem in your code. If you can post some more specific details that would be nice otherwise I will close this ticket. For the record
listdisplay
isn't even a valid option. Neither does
list_display
even mean anything for an inline. ;)
comment:4 by , 17 years ago
You are correct. Sorry for the false alarm.
My MultiWidget had a Select Widget, and the first line of my choices was (None, '------------'). This worked before. None was being recognized as no selection. Now, after the MultiWidget fix, None was being recognized as a selection. I changed the first line of choices to (, '------------'), which corrected the problem.
Not sure how listdisplay got in there originally.
comment:5 by , 17 years ago
WikiFormatting screwed that up. Rather, first choice was changed to:
('', '------------')
comment:6 by , 17 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Can you please provide more specific details? The only change made in [7517] was to the MultiWidget which would indicate the problem still exists with it. You say "extra fields" and I am not sure what exactly you mean?