mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-30 09:14:08 +02:00
Fix SortBox not keeping Sort By input after submission
This commit is contained in:
parent
355618d0e0
commit
95e9117325
@ -144,18 +144,16 @@ class SortBox implements Widget
|
|||||||
$form->setName($this->name);
|
$form->setName($this->name);
|
||||||
$form->addElement(
|
$form->addElement(
|
||||||
'select',
|
'select',
|
||||||
'sort_' . $this->name,
|
'sort',
|
||||||
array(
|
array(
|
||||||
'name' => 'sort',
|
|
||||||
'label' => 'Sort By',
|
'label' => 'Sort By',
|
||||||
'multiOptions' => $this->sortFields
|
'multiOptions' => $this->sortFields
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
$form->addElement(
|
$form->addElement(
|
||||||
'select',
|
'select',
|
||||||
'dir_' . $this->name,
|
'dir',
|
||||||
array(
|
array(
|
||||||
'name' => 'dir',
|
|
||||||
'multiOptions' => array(
|
'multiOptions' => array(
|
||||||
'desc' => 'Desc',
|
'desc' => 'Desc',
|
||||||
'asc' => 'Asc'
|
'asc' => 'Asc'
|
||||||
@ -164,7 +162,7 @@ class SortBox implements Widget
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
$form->enableAutoSubmit(array('sort_' . $this->name, 'dir_' . $this->name));
|
$form->enableAutoSubmit(array('sort', 'dir'));
|
||||||
$form->addElement($this->createFallbackSubmitButton());
|
$form->addElement($this->createFallbackSubmitButton());
|
||||||
|
|
||||||
if ($this->request) {
|
if ($this->request) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user