mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-29 16:54:04 +02:00
Do not consider submit buttons when checking form completion
refs #5525
This commit is contained in:
parent
a73e2ee654
commit
75e09f2c69
@ -232,6 +232,8 @@ class Form extends Zend_Form
|
|||||||
/**
|
/**
|
||||||
* Return whether the given data provides a value for each element of this form
|
* Return whether the given data provides a value for each element of this form
|
||||||
*
|
*
|
||||||
|
* Note that elements that are disabled or of type submit are not taken into consideration.
|
||||||
|
*
|
||||||
* @param array $formData The data to check
|
* @param array $formData The data to check
|
||||||
*
|
*
|
||||||
* @return bool
|
* @return bool
|
||||||
@ -249,7 +251,7 @@ class Form extends Zend_Form
|
|||||||
array_filter(
|
array_filter(
|
||||||
$elements,
|
$elements,
|
||||||
function ($el) {
|
function ($el) {
|
||||||
return $el->getAttrib('disabled') === null;
|
return $el->getAttrib('disabled') === null && $el->getType() !== 'submit';
|
||||||
}
|
}
|
||||||
),
|
),
|
||||||
$formData
|
$formData
|
||||||
|
Loading…
x
Reference in New Issue
Block a user