summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f5ebf9f)
raw | patch | inline | side by side (parent: f5ebf9f)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 7 Sep 2005 12:40:17 +0000 (12:40 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 7 Sep 2005 12:40:17 +0000 (12:40 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@1315 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/admin/FAI/class_faiManagement.inc | patch | blob | history |
index 2738653e8beae08d25da06f2072a036901939916..fb6681453ae5af620be262157bb2cf1f2f3bc202 100644 (file)
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
require "tabsPartition.inc";
+require "tabsScript.inc";
class faiManagement extends plugin
{
/* Edit Entry */
if($s_action == "edit"){
$entry = $this->objects[$s_entry];
- switch($entry['type']){
- case "FAIpartitionTable" :
- $this->dn = $entry['dn'];
- $this->dialog= new tabsPartition($this->config,
- $this->config->data['TABS']['PARTITIONTABS'],$this->dn);
- $this->is_dialog = true;
- ;break;
- default :;break;
- }
-
+
+ $a_setup = ( $this->get_type($entry));
+
+ $this->dn = $entry['dn'];
+ $this->dialog= new $a_setup[0]($this->config,
+ $this->config->data['TABS'][$a_setup[2]],$this->dn);
+ $this->is_dialog = true;
}
$this->dn = "new" ;
$name = $this->dialog->save();
$this->dialog = new tabsPartition($this->config,
- $this->config->data['TABS']['PARTITIONTABS'],$this->dn);
+ $this->config->data['TABS']['FAIPARTITIONTABS'],$this->dn);
$this->dialog->by_object['faiPartitionTable']->cn = $name;
$this->is_dialog = true;
}
function get_type($array){
if(in_array("FAIpartitionTable",$array['objectClass'])){
- return(array("tabsPartition","faiPartitionTable","PARTITIONTABS"));
+ return(array("tabsPartition","faiPartitionTable","FAIPARTITIONTABS"));
+ }
+ if(in_array("FAIscript",$array['objectClass'])){
+ return(array("tabsScript","faiScript","FAISCRIPTTABS"));
}
}