// small fix
This commit is contained in:
@@ -166,18 +166,21 @@ class AdminTabsControllerCore extends AdminController
|
|||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!Validate::isLoadedObject($this->object) || $this->object->id_parent > 0)
|
$display_parent = true;
|
||||||
|
if (Validate::isLoadedObject($this->object) && !class_exists($this->object->class_name.'Controller'))
|
||||||
|
$display_parent = false;
|
||||||
|
|
||||||
$this->fields_form['input'][] = array(
|
if ($display_parent)
|
||||||
'type' => 'select',
|
$this->fields_form['input'][] = array(
|
||||||
'label' => $this->l('Parent:'),
|
'type' => 'select',
|
||||||
'name' => 'id_parent',
|
'label' => $this->l('Parent:'),
|
||||||
'options' => array(
|
'name' => 'id_parent',
|
||||||
'query' => $tabs,
|
'options' => array(
|
||||||
'id' => 'id_tab',
|
'query' => $tabs,
|
||||||
'name' => 'name'
|
'id' => 'id_tab',
|
||||||
)
|
'name' => 'name'
|
||||||
);
|
)
|
||||||
|
);
|
||||||
|
|
||||||
return parent::renderForm();
|
return parent::renderForm();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user