Page MenuHomePhabricator

Codex Special:Block - when editing an existing block most of the form fields don't reflect what's stored
Closed, ResolvedPublicBUG REPORT

Description

Steps to reproduce:

  • go to https://test.wikipedia.beta.wmflabs.org/wiki/Special:Block and create a block for a user:
    • set a custom duration
    • choose a non-default reason, and enter some text for an additional reason
    • select all the checkboxes under "Block details (optional)"
    • un-select the "Automatically block the last IP address ..." checkbox
    • select the "Watch this user's user and talk pages" checkbox
  • create the block
  • go to the Active Blocks list, and click the menu item to edit the user
  • the block type is loaded ok, but everything else (duration, reason and all the checkboxes (including any of the checkboxes set during a partial block)) reverts to the default rather than what was set when creating the block

Derived Requirement

Ensure that when editing an existing block via the Special:Block page, all form fields (duration, reason, additional reason, checkboxes, and block details) reflect the values stored during the block creation process.

Test Steps

Test Case 1: Verify Consistency Across Form Fields for Edited Blocks

  1. Follow the steps from the task description.
  2. ✅❓❌⬜ AC1: Verify that all form fields (duration, reason, additional reason, checkboxes) display the values set during block creation without reverting to defaults.

QA Results - Test Wiki

ACStatusDetails
1T380963#10415357

Event Timeline

Cparle renamed this task from Codex Special:Block - when editing an existing block most of the form fields don't reflect to Codex Special:Block - when editing an existing block most of the form fields don't reflect what's stored.Nov 27 2024, 10:44 AM
Cparle updated the task description. (Show Details)
KSiebert changed the subtype of this task from "Task" to "Bug Report".Nov 27 2024, 12:28 PM

Change #1097656 had a related patch set uploaded (by MusikAnimal; author: MusikAnimal):

[mediawiki/core@master] SpecialBlock.vue: update form fields when loading a blocked user

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

MusikAnimal changed the task status from Open to Stalled.Dec 2 2024, 11:25 PM

Change #1097656 abandoned by MusikAnimal:

[mediawiki/core@master] SpecialBlock.vue: update form fields when loading a blocked user

Reason:

UI is being reworked. Bits of this code may find its way to other patches, but it's mostly unmerge-able with the new product requirements

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

Samwilson changed the task status from Stalled to Open.Thu, Dec 12, 2:34 AM

Change #1102527 had a related patch set uploaded (by Samwilson; author: Samwilson):

[mediawiki/core@master] SpecialBlock: Add remaining form fields to editing

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

Change #1102527 merged by jenkins-bot:

[mediawiki/core@master] SpecialBlock: Add remaining form fields to editing

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

Moving back to in-dev to fix up the expiry field handling.

Change #1104405 had a related patch set uploaded (by Samwilson; author: Samwilson):

[mediawiki/core@master] SpecialBlock: Handle expiry datetime in JS the same as in PHP

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

Samwilson added a subscriber: TheresNoTime.

@TheresNoTime thanks for pointing out the expiry time issue, hopefully the above fixes it.

Change #1104405 merged by jenkins-bot:

[mediawiki/core@master] SpecialBlock: Handle expiry datetime in JS the same as in PHP

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

GMikesell-WMF updated Other Assignee, added: GMikesell-WMF.
GMikesell-WMF updated the task description. (Show Details)
GMikesell-WMF subscribed.

@Samwilson Verified that all form fields (duration, reason, additional reason, checkboxes) display the values set during block creation without reverting to defaults as seen in the gif below. I will move this to Done. Thanks for all your work!

Test Result - Test Wiki

Status: ✅ PASS
Environment: Test Wiki
OS: macOS Sonoma 15.1
Browser: Chrome 131
Device: MBA
Emulated Device: NA

Test Artifact(s):

Test Steps

Test Case 1: Verify Consistency Across Form Fields for Edited Blocks

  1. Follow the steps from the task description.
  2. AC1: Verify that all form fields (duration, reason, additional reason, checkboxes) display the values set during block creation without reverting to defaults.

2024-12-19_02-12-10.mp4.gif (728×1 px, 3 MB)

GMikesell-WMF updated Other Assignee, removed: GMikesell-WMF.
GMikesell-WMF moved this task from QA to Done on the Community-Tech (Jackal (not a fox) Fox) board.
  NODES
COMMUNITY 7
Note 3
Project 7
Verify 4