mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-27 15:54:03 +02:00
parent
d2341369a9
commit
b0221c5e13
@ -1105,10 +1105,11 @@ class Form extends Zend_Form
|
|||||||
*/
|
*/
|
||||||
protected function preserveDefaults(Zend_Form $form, array & $defaults)
|
protected function preserveDefaults(Zend_Form $form, array & $defaults)
|
||||||
{
|
{
|
||||||
foreach ($form->getElements() as $name => $_) {
|
foreach ($form->getElements() as $name => $element) {
|
||||||
if (array_key_exists($name, $defaults)
|
if ((array_key_exists($name, $defaults)
|
||||||
&& array_key_exists($name . static::DEFAULT_SUFFIX, $defaults)
|
&& array_key_exists($name . static::DEFAULT_SUFFIX, $defaults)
|
||||||
&& $defaults[$name] === $defaults[$name . static::DEFAULT_SUFFIX]
|
&& $defaults[$name] === $defaults[$name . static::DEFAULT_SUFFIX])
|
||||||
|
|| $element->getAttrib('disabled')
|
||||||
) {
|
) {
|
||||||
unset($defaults[$name]);
|
unset($defaults[$name]);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user