Code

Opened 7 years ago

Closed 13 months ago

#5116 closed New feature (duplicate)

newforms: SelectMultiple widget: disable some entries

Reported by: Thomas Güttler <hv@…> Owned by: PhiR
Component: Forms Version: master
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)

newforms_widgets_selectm_disable.diff (1.6 KB) - added by Thomas Güttler <hv@…> 7 years ago.
newforms_select_disable.diff (5.3 KB) - added by Thomas Güttler <hv@…> 7 years ago.
newforms_select_disable-2.diff (5.3 KB) - added by Thomas Güttler <hv@…> 6 years ago.

Download all attachments as: .zip

Change History (16)

Changed 7 years ago by Thomas Güttler <hv@…>

comment:1 Changed 7 years ago by PhiR

  • Keywords feature added
  • Needs documentation set
  • Needs tests unset
  • Owner changed from nobody to PhiR
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Design decision needed

comment:2 Changed 7 years ago by Thomas Güttler <hv@…>

  • Cc hv@… added

Changed 7 years ago by Thomas Güttler <hv@…>

comment:3 Changed 7 years ago by Thomas Güttler <hv@…>

  • Has patch unset
  • Needs documentation unset

I attached a new patch. It includes documentation an tests.

comment:4 Changed 7 years ago by Thomas Güttler <hv@…>

  • Has patch set

Changed 6 years ago by Thomas Güttler <hv@…>

comment:5 Changed 6 years ago by Thomas Güttler <hv@…>

newforms_select_disable-2.diff is an update to apply cleanly to the current trunk.

comment:6 Changed 6 years ago by PhiR

  • Triage Stage changed from Design decision needed to Ready for checkin

tests are working, documentation is up to date.

comment:7 Changed 6 years ago by mtredinnick

  • Triage Stage changed from Ready for checkin to 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 Changed 6 years ago by PhiR

  • 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 Changed 4 years ago by russellm

  • Triage Stage changed from Design decision needed to Accepted

This is an option in the HTML spec, so we should be able to expose it in some way.

comment:10 Changed 3 years ago by gabrielhurley

  • Severity set to Normal
  • Type set to New feature

comment:11 Changed 2 years ago by aaugustin

  • UI/UX unset

Change UI/UX from NULL to False.

comment:12 Changed 2 years ago by aaugustin

  • Easy pickings unset

Change Easy pickings from NULL to False.

comment:13 Changed 13 months ago by bmispelon

  • Cc bmispelon@… added
  • Resolution set to duplicate
  • Status changed from new to closed

This is a duplicate of #16149 which also has a patch but is a bit more generic.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.