Page MenuHomePhabricator

SecurePoll: Custom column labels not disabled when editing a running election
Closed, ResolvedPublic3 Estimated Story PointsBUG REPORT

Description

What is the problem?

When editing an election that is currently running, the custom column labels are editable when they should be disabled.

Any edits you make to them are not saved to the database, so this is only an aesthetic/UI bug.

Steps to reproduce problem
  1. Go to Special:SecurePoll/create
  2. Set "Election Start Date" to today's date
  3. For "poll type" choose one of the "range" types
  4. On one of the questions, check "Use custom messages for column labels"
  5. Fill in the rest of the form and submit
  6. Edit the election you just created

Expected behavior: The custom column labels are disabled/greyed out
Observed behavior: The custom column labels are editable

Environment

Browser: Firefox 78
Wiki(s): https://vote.wikimedia.beta.wmflabs.org SecurePoll 2.0.0 (0ef20d9) 07:52, 12 February 2021.

Screenshots (if applicable):

Event Timeline

Niharika triaged this task as Medium priority.Feb 17 2021, 4:58 PM

Change 666232 had a related patch set uploaded (by STran; owner: STran):
[mediawiki/extensions/SecurePoll@master] Pass along the disabled param to HTMLFormRadioRangeColumnLabels

https://gerrit.wikimedia.org/r/666232

Change 666232 merged by jenkins-bot:
[mediawiki/extensions/SecurePoll@master] Pass along the disabled param to HTMLFormRadioRangeColumnLabels

https://gerrit.wikimedia.org/r/666232

The column labels are now correctly disabled if the election is running:

You can still edit them before the election starts.

Test Environment: https://vote.wikimedia.beta.wmflabs.org SecurePoll 2.0.0 (53ccff9) 22:28, 1 March 2021.