mirror of
https://github.com/e107inc/e107.git
synced 2025-07-31 20:00:37 +02:00
Fixed #366 - introduced new $preftabs UI variable, identical to tabs but
referenced from $prefs instead $fields data.
This commit is contained in:
@@ -2336,6 +2336,13 @@ class e_admin_controller_ui extends e_admin_controller
|
|||||||
*/
|
*/
|
||||||
protected $tabs = array();
|
protected $tabs = array();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Example: array('0' => 'Tab label', '1' => 'Another label');
|
||||||
|
* Referenced from $prefs property per field - 'tab => xxx' where xxx is the tab key (identifier)
|
||||||
|
* @var array edit/create form tabs
|
||||||
|
*/
|
||||||
|
protected $preftabs = array();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* TODO Example:
|
* TODO Example:
|
||||||
* Contains required data for auto-assembling URL from every record
|
* Contains required data for auto-assembling URL from every record
|
||||||
@@ -2465,7 +2472,6 @@ class e_admin_controller_ui extends e_admin_controller
|
|||||||
return deftrue($this->pluginTitle, $this->pluginTitle);
|
return deftrue($this->pluginTitle, $this->pluginTitle);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get Tab data
|
* Get Tab data
|
||||||
* @return array
|
* @return array
|
||||||
@@ -2475,6 +2481,14 @@ class e_admin_controller_ui extends e_admin_controller
|
|||||||
return $this->tabs;
|
return $this->tabs;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get Tab data
|
||||||
|
* @return array
|
||||||
|
*/
|
||||||
|
public function getPrefTabs()
|
||||||
|
{
|
||||||
|
return $this->preftabs;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get URL profile
|
* Get URL profile
|
||||||
@@ -5153,7 +5167,7 @@ class e_admin_form_ui extends e_form
|
|||||||
'tabs' => false, // TODO - NOT IMPLEMENTED YET - enable tabs (only if fieldset count is > 1)
|
'tabs' => false, // TODO - NOT IMPLEMENTED YET - enable tabs (only if fieldset count is > 1)
|
||||||
'fieldsets' => array(
|
'fieldsets' => array(
|
||||||
'settings' => array(
|
'settings' => array(
|
||||||
'tabs' => $controller->getTabs(), //used within a single form.
|
'tabs' => $controller->getPrefTabs(), //used within a single form.
|
||||||
'legend' => $legend,
|
'legend' => $legend,
|
||||||
'fields' => $controller->getPrefs(), //see e_admin_ui::$prefs
|
'fields' => $controller->getPrefs(), //see e_admin_ui::$prefs
|
||||||
'after_submit_options' => false,
|
'after_submit_options' => false,
|
||||||
|
Reference in New Issue
Block a user