Opened 19 years ago
Closed 18 years ago
#1568 closed defect (wontfix)
[patch] CharFields with small maxlength are still displayed with a size of 30
Reported by: | Owned by: | Adrian Holovaty | |
---|---|---|---|
Component: | contrib.admin | Version: | dev |
Severity: | trivial | Keywords: | |
Cc: | Triage Stage: | Ready for checkin | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
All of the CharFields are displayed as text input fields with a size of 30, even when the maxlength is much smaller. This can create confusion when the user is unable to type letters in an almost empty field.
Attachments (1)
Change History (5)
comment:1 by , 18 years ago
Version: | → SVN |
---|
by , 18 years ago
Attachment: | charfield_size.diff added |
---|
comment:2 by , 18 years ago
Summary: | CharFields with small maxlength are still displayed with a size of 30 → [patch] CharFields with small maxlength are still displayed with a size of 30 |
---|
comment:3 by , 18 years ago
Triage Stage: | Unreviewed → Ready for checkin |
---|
comment:4 by , 18 years ago
Resolution: | → wontfix |
---|---|
Status: | new → closed |
The oldforms package has been end-of-lifed now, so we are not going to be applying any further enhancements like this to it. We do want to check that the same problem doesn't appear on newforms, though.
[For the record, there is a problem with this patch as it stands: it should only trim the length for really short fields. Otherwise, a field with a maxlength of 200 will destroy the form layout. So some kind of check that it only adjusts the length to maxlength if maxlength < 30 would be required. That is why self.length exists in the first place. It should also probably have had a minimum of 2 or 3 on the length.]
This is indeed true for the SVN branch.