The URL from the serialized form was something like:
&wpoptions%5B%5D=editsOnly
whereas we needed:
&editsOnly=1
Bug: T171332
Change-Id: Iaec223195e121dab83b5605a3dfaffa8e1f93684
$groupOptions[ $groupText ] = $group;
}
$groupOptions[ $groupText ] = $group;
}
- $optionsDefault = [];
- if ( $this->editsOnly ) {
- $optionsDefault[] = 'editsOnly';
- }
- if ( $this->creationSort ) {
- $optionsDefault[] = 'creationSort';
- }
- if ( $this->mDefaultDirection ) {
- $optionsDefault[] = 'desc';
- }
-
$formDescriptor = [
'user' => [
'class' => 'HTMLUserTextField',
$formDescriptor = [
'user' => [
'class' => 'HTMLUserTextField',
'class' => 'HTMLSelectField',
'options' => $groupOptions,
],
'class' => 'HTMLSelectField',
'options' => $groupOptions,
],
- 'options' => [
- 'class' => 'HTMLMultiSelectField',
- 'options' => [
- $this->msg( 'listusers-editsonly' )->text() => 'editsOnly',
- $this->msg( 'listusers-creationsort' )->text() => 'creationSort',
- $this->msg( 'listusers-desc' )->text() => 'desc'
- ],
- 'default' => $optionsDefault
+ 'editsOnly' => [
+ 'type' => 'check',
+ 'label' => $this->msg( 'listusers-editsonly' )->text(),
+ 'name' => 'editsOnly',
+ 'id' => 'editsOnly',
+ 'value' => $this->editsOnly
+ ],
+ 'creationSort' => [
+ 'type' => 'check',
+ 'label' => $this->msg( 'listusers-creationsort' )->text(),
+ 'name' => 'creationSort',
+ 'id' => 'creationSort',
+ 'value' => $this->creationSort
+ ],
+ 'desc' => [
+ 'type' => 'check',
+ 'label' => $this->msg( 'listusers-desc' )->text(),
+ 'name' => 'desc',
+ 'id' => 'desc',
+ 'value' => $this->mDefaultDirection
],
'limithiddenfield' => [
'class' => 'HTMLHiddenField',
],
'limithiddenfield' => [
'class' => 'HTMLHiddenField',