DirectorDatafieldForm: fix typo, translate
This commit is contained in:
parent
71b311e258
commit
62f59d4c5a
|
@ -165,7 +165,7 @@ class DirectorDatafieldForm extends DirectorObjectForm
|
|||
|
||||
$this->addElement('select', 'category_id', [
|
||||
'label' => $this->translate('Data Field Category'),
|
||||
'multiOptions' => $this->optionalEnum($this->enumCategpories()),
|
||||
'multiOptions' => $this->optionalEnum($this->enumCategories()),
|
||||
]);
|
||||
|
||||
$error = false;
|
||||
|
@ -281,7 +281,7 @@ class DirectorDatafieldForm extends DirectorObjectForm
|
|||
protected function enumDataTypes()
|
||||
{
|
||||
$hooks = Hook::all('Director\\DataType');
|
||||
$enum = array(null => '- please choose -');
|
||||
$enum = [null => $this->translate('- please choose -')];
|
||||
/** @var DataTypeHook $hook */
|
||||
foreach ($hooks as $hook) {
|
||||
$enum[get_class($hook)] = $hook->getName();
|
||||
|
@ -290,7 +290,7 @@ class DirectorDatafieldForm extends DirectorObjectForm
|
|||
return $enum;
|
||||
}
|
||||
|
||||
protected function enumCategpories()
|
||||
protected function enumCategories()
|
||||
{
|
||||
$db = $this->getDb()->getDbAdapter();
|
||||
return $db->fetchPairs(
|
||||
|
|
Loading…
Reference in New Issue