Opened 18 years ago
Closed 13 years ago
#5116 closed New feature (duplicate)
newforms: SelectMultiple widget: disable some entries
| Reported by: | Owned by: | Philippe Raoult | |
|---|---|---|---|
| Component: | Forms | Version: | dev |
| Severity: | Normal | Keywords: | feature |
| Cc: | hv@…, bmispelon@… | Triage Stage: | Accepted |
| Has patch: | yes | Needs documentation: | no |
| Needs tests: | no | Patch needs improvement: | yes |
| Easy pickings: | no | UI/UX: | no |
Description
Hi,
here is a small patch to disable some items in a
SelectMultiple widget.
Attachments (3)
Change History (16)
by , 18 years ago
| Attachment: | newforms_widgets_selectm_disable.diff added |
|---|
comment:1 by , 18 years ago
| Keywords: | feature added |
|---|---|
| Needs documentation: | set |
| Owner: | changed from to |
| Triage Stage: | Unreviewed → Design decision needed |
comment:2 by , 18 years ago
| Cc: | added |
|---|
by , 18 years ago
| Attachment: | newforms_select_disable.diff added |
|---|
comment:3 by , 18 years ago
| Has patch: | unset |
|---|---|
| Needs documentation: | unset |
comment:4 by , 18 years ago
| Has patch: | set |
|---|
by , 18 years ago
| Attachment: | newforms_select_disable-2.diff added |
|---|
comment:5 by , 18 years ago
newforms_select_disable-2.diff is an update to apply cleanly to the current trunk.
comment:6 by , 18 years ago
| Triage Stage: | Design decision needed → Ready for checkin |
|---|
tests are working, documentation is up to date.
comment:7 by , 18 years ago
| Triage Stage: | Ready for checkin → Design decision needed |
|---|
Best practice is to leave out entries that cannot be selected, not disable them. So it's not clear that this is a good change to make.
comment:8 by , 18 years ago
| Patch needs improvement: | set |
|---|
We could accept a patch that makes it easier to subclass Select though. Then you can post your disable option as a snippet subclassing Select.
comment:9 by , 15 years ago
| Triage Stage: | Design decision needed → Accepted |
|---|
This is an option in the HTML spec, so we should be able to expose it in some way.
comment:10 by , 15 years ago
| Severity: | → Normal |
|---|---|
| Type: | → New feature |
comment:13 by , 13 years ago
| Cc: | added |
|---|---|
| Resolution: | → duplicate |
| Status: | new → closed |
This is a duplicate of #16149 which also has a patch but is a bit more generic.
I attached a new patch. It includes documentation an tests.