DirectorObjectForm: move valueIsEmpty to QuickBase

This commit is contained in:
Thomas Gelf 2016-03-24 02:27:10 +01:00
parent 5fc16f393d
commit b09593ff75
2 changed files with 9 additions and 9 deletions

View File

@ -1024,15 +1024,6 @@ abstract class DirectorObjectForm extends QuickForm
return ! $this->valueIsEmpty($this->getSentOrObjectValue('object_type'));
}
protected function valueIsEmpty($value)
{
if (is_array($value)) {
return empty($value);
}
return strlen($value) === 0;
}
protected function addZoneElement()
{
if ($this->isTemplate()) {

View File

@ -109,6 +109,15 @@ abstract class QuickBaseForm extends Zend_Form
return FormLoader::load($name, $module);
}
protected function valueIsEmpty($value)
{
if (is_array($value)) {
return empty($value);
}
return strlen($value) === 0;
}
public function translate($string)
{
if ($this->icingaModuleName === null) {