summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: cab346b)
raw | patch | inline | side by side (parent: cab346b)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 10 May 2010 13:32:52 +0000 (13:32 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 10 May 2010 13:32:52 +0000 (13:32 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18268 594d385d-05f5-0310-b6e9-bd551577e9d8
17 files changed:
diff --git a/gosa-plugins/fai/admin/fai/class_faiHook.inc b/gosa-plugins/fai/admin/fai/class_faiHook.inc
index f0c0a6d0140d5df83ed4490cd1bb1c5bb22b3105..02b5719c3d14d30ea8bd54dd925725868de41bbe 100644 (file)
*/
if($this->is_new){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiHookRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiHook", "faiHookRDN") .get_ou("faiHook", "faiHookRDN") .$release;
$res = faiManagement::check_class_name("FAIhook",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_faiManagement.inc b/gosa-plugins/fai/admin/fai/class_faiManagement.inc
index d07cbe93daf7b0b5deb7b80714fad302156522df..a71d286e90b685f2f2a8fcd1e2a42d23114f530e 100644 (file)
$this->opsi = new opsi($this->config);;
}
- $this->fai_base = get_ou("faiBaseRDN").$this->config->current['BASE'];
+ $this->fai_base = get_ou("mimetype", "mimetypeRDN") .$this->config->current['BASE'];
$cfg_rel = $this->config->get_cfg_value("faiManagement","defaultFaiRelease");
if(!empty($cfg_rel)){
$this->acl_base = $this->config->current['BASE'];
$this->ui = $ui;
$this->storagePoints = array(
- get_ou('faiPartitionRDN'),
- get_ou('faiPackageRDN'),
- get_ou('faiScriptRDN'),
- get_ou('faiVariableRDN'),
- get_ou('faiHookRDN'),
- get_ou('faiProfileRDN'),
- get_ou('faiTemplateRDN'));
+ get_ou("mimetype", "mimetypeRDN") ,
+ get_ou("mimetype", "mimetypeRDN") ,
+ get_ou("mimetype", "mimetypeRDN") ,
+ get_ou("mimetype", "mimetypeRDN") ,
+ get_ou("mimetype", "mimetypeRDN") ,
+ get_ou("mimetype", "mimetypeRDN") ,
+ get_ou("mimetype", "mimetypeRDN") );
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
$ldap->cd($bb);
$ldap->recursive_remove();
- $ldap->cd(preg_replace('/,'.preg_quote(get_ou('faiBaseRDN'), '/').'/i', ','.get_ou('applicationRDN'), $bb));
+ $ldap->cd(preg_replace('/,'.preg_quote(get_ou("mimetype", "mimetypeRDN") , '/').'/i', ','.get_ou("mimetype", "mimetypeRDN") , $bb));
$ldap->recursive_remove();
- $ldap->cd(preg_replace('/,'.preg_quote(get_ou('faiBaseRDN'), '/').'/i', ','.get_ou('mimetypeRDN'), $bb));
+ $ldap->cd(preg_replace('/,'.preg_quote(get_ou("mimetype", "mimetypeRDN") , '/').'/i', ','.get_ou("mimetype", "mimetypeRDN") , $bb));
$ldap->recursive_remove();
/* Search for all groups with configured application menus.
- The search für menu configuration for the specified release and collect all those dns.
- Remove entries
*/
- $release_ou = preg_replace("/".preg_quote(get_ou("faiBaseRDN"), '/').".*$/i","",$bb);
+ $release_ou = preg_replace("/".preg_quote(get_ou("mimetype", "mimetypeRDN") , '/').".*$/i","",$bb);
$ldap->cd($this->config->current['BASE']);
$ldap->search("(objectClass=posixGroup)",array("dn"));
$targetReleaseDN = "ou=".$name.",".$baseToUse;
- $appsrc = preg_replace("/".preg_quote(get_ou('faiBaseRDN'), '/')."/i",get_ou('applicationRDN'),$baseToUse);
- $appdst = preg_replace("/".preg_quote(get_ou('faiBaseRDN'), '/')."/i",get_ou('applicationRDN'),"ou=".$name.",".$baseToUse) ;
+ $appsrc = preg_replace("/".preg_quote(get_ou("mimetype", "mimetypeRDN") , '/')."/i",get_ou("mimetype", "mimetypeRDN") ,$baseToUse);
+ $appdst = preg_replace("/".preg_quote(get_ou("mimetype", "mimetypeRDN") , '/')."/i",get_ou("mimetype", "mimetypeRDN") ,"ou=".$name.",".$baseToUse) ;
- $mimesrc = preg_replace("/".preg_quote(get_ou('faiBaseRDN'), '/')."/i",get_ou('mimetypeRDN'),$baseToUse);
- $mimedst = preg_replace("/".preg_quote(get_ou('faiBaseRDN'), '/')."/i",get_ou('mimetypeRDN'),"ou=".$name.",".$baseToUse) ;
+ $mimesrc = preg_replace("/".preg_quote(get_ou("mimetype", "mimetypeRDN") , '/')."/i",get_ou("mimetype", "mimetypeRDN") ,$baseToUse);
+ $mimedst = preg_replace("/".preg_quote(get_ou("mimetype", "mimetypeRDN") , '/')."/i",get_ou("mimetype", "mimetypeRDN") ,"ou=".$name.",".$baseToUse) ;
/* Check if source depeartments exist */
foreach(array($baseToUse,$appsrc,$mimesrc) as $dep){
diff --git a/gosa-plugins/fai/admin/fai/class_faiPackage.inc b/gosa-plugins/fai/admin/fai/class_faiPackage.inc
index 3657b9f6b1bed395182249711b0fa7d760085fb4..6a93d97326fab7275f8ad478d4cfe77afe9bbff4 100644 (file)
/* Assemble release name */
$release = $this->parent->parent->fai_release;
- $tmp= preg_replace('/[,]*'.preg_quote(get_ou('faiBaseRDN'), '/').'.*$/i', '', $release);
+ $tmp= preg_replace('/[,]*'.preg_quote(get_ou("faiPackage", "faiPackageRDN") , '/').'.*$/i', '', $release);
$tmp= preg_replace('/ou=/', '', $tmp);
$rev= array_reverse(explode(',', $tmp));
$this->FAIdebianRelease= "/";
*/
if($this->is_new){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiPackageRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiPackage", "faiPackageRDN") .get_ou("faiPackage", "faiPackageRDN") .$release;
$res = faiManagement::check_class_name("FAIpackageList",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
if($this->FAIdebianRelease == "ClearFromCopyPaste"){
$current_release = $this->parent->parent->fai_release;
- $tmp= preg_replace('/,'.preg_quote(get_ou('faiBaseRDN'), '/').'.*$/i', '', $current_release);
+ $tmp= preg_replace('/,'.preg_quote(get_ou("faiPackage", "faiPackageRDN") , '/').'.*$/i', '', $current_release);
$tmp= preg_replace('/ou=/', '', $tmp);
$rev= array_reverse(explode(',', $tmp));
$this->FAIdebianRelease= "";
diff --git a/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc b/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc
index 9e4c14deaaa3f38a14aaf20ec8475666a867cc69..5673f307eeb5b852ce7850fa9ba3851adf15fae7 100644 (file)
*/
if($this->is_new){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiPartitionRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiPartitionTable", "faiPartitionRDN") .get_ou("faiPartitionTable", "faiPartitionRDN") .$release;
$res = faiManagement::check_class_name("FAIpartitionTable",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_faiProfile.inc b/gosa-plugins/fai/admin/fai/class_faiProfile.inc
index 2d6fb5b8ba73d2e435ca431409dfc32a63c79a94..921537d65aef324a119dab53d97752584acf8e96 100644 (file)
*/
if($this->dn == "new" || $this->cn != $this->old_cn){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiProfileRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiProfile", "faiProfileRDN") .get_ou("faiProfile", "faiProfileRDN") .$release;
$res = faiManagement::check_class_name("FAIprofile",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_faiScript.inc b/gosa-plugins/fai/admin/fai/class_faiScript.inc
index d8283a973dcc6b0998dd9e8a275ac14c454d53c8..9927b089be1dd945ff5d24422a0acba4220611f7 100644 (file)
*/
if($this->is_new){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiScriptRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiScript", "faiScriptRDN") .get_ou("faiScript", "faiScriptRDN") .$release;
$res = faiManagement::check_class_name("FAIscript",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_faiSummaryTab.inc b/gosa-plugins/fai/admin/fai/class_faiSummaryTab.inc
index 16ab54023609f278bd52c43b9e2b84230b7d08b4..31878b91b0d25d57b154f3584b64fe618a1b5668 100644 (file)
/* Base object configuration */
$this->objs = array(
- "FAIscript" => array( "Image" =>"plugins/fai/images/fai_script.png", "Name"=>_("Scripts") ,"Tree" =>get_ou('faiScriptRDN')) ,
- "FAIhook" => array( "Image" =>"plugins/fai/images/fai_hook.png" , "Name"=>_("Hooks") ,"Tree" =>get_ou('faiHookRDN')),
- "FAIvariable" => array( "Image" =>"plugins/fai/images/fai_variable.png", "Name"=>_("Variables") ,"Tree" =>get_ou('faiVariableRDN')) ,
- "FAItemplate" => array( "Image" =>"plugins/fai/images/fai_template.png", "Name"=>_("Templates") ,"Tree" =>get_ou('faiTemplateRDN')) ,
- "FAIpartitionTable" => array( "Image" =>"plugins/fai/images/fai_partitionTable.png","Name"=>_("Partition table") ,"Tree" =>get_ou('faiPartitionRDN')) ,
- "FAIpackageList" => array( "Image" =>"plugins/fai/images/fai_packages.png", "Name"=>_("Package list") ,"Tree" =>get_ou('faiPackageRDN')) ,
- "FAIprofile" => array( "Image" =>"plugins/fai/images/fai_profile.png", "Name"=>_("Profiles") ,"Tree" =>get_ou('faiProfileRDN')));
+ "FAIscript" => array( "Image" =>"plugins/fai/images/fai_script.png", "Name"=>_("Scripts") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ) ,
+ "FAIhook" => array( "Image" =>"plugins/fai/images/fai_hook.png" , "Name"=>_("Hooks") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ),
+ "FAIvariable" => array( "Image" =>"plugins/fai/images/fai_variable.png", "Name"=>_("Variables") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ) ,
+ "FAItemplate" => array( "Image" =>"plugins/fai/images/fai_template.png", "Name"=>_("Templates") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ) ,
+ "FAIpartitionTable" => array( "Image" =>"plugins/fai/images/fai_partitionTable.png","Name"=>_("Partition table") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ) ,
+ "FAIpackageList" => array( "Image" =>"plugins/fai/images/fai_packages.png", "Name"=>_("Package list") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ) ,
+ "FAIprofile" => array( "Image" =>"plugins/fai/images/fai_profile.png", "Name"=>_("Profiles") ,"Tree" =>get_ou("faiTemplate", "faiTemplateRDN") ));
}
/* Get Classes and release */
$this->Classes = $this->parent->by_object['faiProfile']->FAIclasses;
$this->base = $this->parent->by_object['faiProfile']->parent->parent->fai_release;
- $str = preg_replace("/^.*".preg_quote(get_ou('faiProfileRDN'), '/')."/i","",$this->dn);
+ $str = preg_replace("/^.*".preg_quote(get_ou("faiTemplate", "faiTemplateRDN") , '/')."/i","",$this->dn);
$tmp = $this->parent->by_object['faiProfile']->parent->parent->getBranches();
$this->Release = $tmp[$this->base];
diff --git a/gosa-plugins/fai/admin/fai/class_faiTemplate.inc b/gosa-plugins/fai/admin/fai/class_faiTemplate.inc
index 4ece4344c030ba81d9190eef9c3e9a4c92da017f..27591a8c4f636049a1605b49c3f4eaae2005d06e 100644 (file)
*/
if($this->is_new){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiTemplateRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiTemplate", "faiTemplateRDN") .get_ou("faiTemplate", "faiTemplateRDN") .$release;
$res = faiManagement::check_class_name("FAItemplate",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_faiVariable.inc b/gosa-plugins/fai/admin/fai/class_faiVariable.inc
index 78546c48361f1cee7689e2377baf375726243336..8fce416eb6d06ed600baceba5816d8452d99f6ad 100644 (file)
*/
if($this->is_new){
$release = $this->parent->parent->fai_release;
- $new_dn= 'cn='.$this->cn.",".get_ou('faiVariableRDN').get_ou('faiBaseRDN').$release;
+ $new_dn= 'cn='.$this->cn.",".get_ou("faiVariable", "faiVariableRDN") .get_ou("faiVariable", "faiVariableRDN") .$release;
$res = faiManagement::check_class_name("FAIvariable",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_filterFAI.inc b/gosa-plugins/fai/admin/fai/class_filterFAI.inc
index 155b95e4730772a9abb42af1a52db657c8940903..c2707b218acda6d0d6ffe2259b901c575953b16b 100644 (file)
* Generate List of Partitions,Hooks,Scripts,Templates,Profiles ...
*/
$ObjectTypes = array(
- "FAIpartitionTable" => array("OU"=> get_ou('faiPartitionRDN') , "CHKBOX"=>"ShowPartitions" ,
+ "FAIpartitionTable" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowPartitions" ,
"ACL" => "faiPartitionTable"),
- "FAIpackageList" => array("OU"=> get_ou('faiPackageRDN') , "CHKBOX"=>"ShowPackages" ,
+ "FAIpackageList" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowPackages" ,
"ACL" => "faiPackage"),
- "FAIscript" => array("OU"=> get_ou('faiScriptRDN') , "CHKBOX"=>"ShowScripts" ,
+ "FAIscript" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowScripts" ,
"ACL" => "faiScript"),
- "FAIvariable" => array("OU"=> get_ou('faiVariableRDN') , "CHKBOX"=>"ShowVariables" ,
+ "FAIvariable" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowVariables" ,
"ACL" => "faiVariable"),
- "FAIhook" => array("OU"=> get_ou('faiHookRDN') , "CHKBOX"=>"ShowHooks" ,
+ "FAIhook" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowHooks" ,
"ACL" => "faiHook"),
- "FAIprofile" => array("OU"=> get_ou('faiProfileRDN') , "CHKBOX"=>"ShowProfiles" ,
+ "FAIprofile" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowProfiles" ,
"ACL" => "faiProfile"),
- "FAItemplate" => array("OU"=> get_ou('faiTemplateRDN') , "CHKBOX"=>"ShowTemplates" ,
+ "FAItemplate" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowTemplates" ,
"ACL" => "faiTemplate"));
/* Clean up object informations */
$obj = array();
$obj['cn'] = $object['cn'][0];
- $obj['dn'] = $object['cn'][0].",".get_ou("faiBaseRDN").$config->current['BASE'];
+ $obj['dn'] = $object['cn'][0].",".get_ou("faiTemplate", "faiTemplateRDN") .$config->current['BASE'];
$obj['acl'] = $acl;
$obj['class'] = $rest ['ACL'];
$obj['FAIstate'] = $entry['FAIstate'];
// Append opsi stuff ...
- if(class_available('opsi') && $base == get_ou("faiBaseRDN").$config->current['BASE']){
+ if(class_available('opsi') && $base == get_ou("faiTemplate", "faiTemplateRDN") .$config->current['BASE']){
$opsi = new opsi($config);
$objects = array();
if($opsi instanceof opsi && $opsi->enabled()){
index 40c997c767e8378f8b81c71c26c294a2683db3dc..a64166ff365c69a6b4fb1b6b644147b9f87c13df 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['faiHook'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiHookRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiHook", "faiHookRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){
diff --git a/gosa-plugins/fai/admin/fai/tabsPackage.inc b/gosa-plugins/fai/admin/fai/tabsPackage.inc
index 835933f79a9617d484b2f48688242ebe11274544..c134dccdb5670f6ee844e4006c1d4fc0d96fe1f7 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['faiPackage'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiPackageRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiPackage", "faiPackageRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){
diff --git a/gosa-plugins/fai/admin/fai/tabsPartition.inc b/gosa-plugins/fai/admin/fai/tabsPartition.inc
index 3ac0e2257d92261f9e529183851860b777e61893..f7a4815392b2e2ee0ef9ea698fe81b1338010298 100644 (file)
{
$baseobject= $this->by_object['faiPartitionTable'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiPartitionRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiPartitionTable", "faiPartitionRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){
diff --git a/gosa-plugins/fai/admin/fai/tabsProfile.inc b/gosa-plugins/fai/admin/fai/tabsProfile.inc
index 3773637e0f4079ab251075b79bd2736d106f55d2..4d1450712b465fc89e1eca18b8a071341a116d9a 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['faiProfile'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiProfileRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiProfile", "faiProfileRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){
index 7cf0a027e2fd887c1991104ba7e07c49f8c16d4f..692b6d5499b6ec8905ddffe565343ee6a7f9ed10 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['faiScript'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiScriptRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiScript", "faiScriptRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){
diff --git a/gosa-plugins/fai/admin/fai/tabsTemplate.inc b/gosa-plugins/fai/admin/fai/tabsTemplate.inc
index e47096fd32b3782c39e208712faca501967f784a..2f1b43b34b4635e891dcb631a2accff699abfb9f 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['faiTemplate'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiTemplateRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiTemplate", "faiTemplateRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){
diff --git a/gosa-plugins/fai/admin/fai/tabsVariable.inc b/gosa-plugins/fai/admin/fai/tabsVariable.inc
index 5a636be08f206391d354ba452ea3d9924147e5d9..dd9f8da715c3dbc4b44fedb46e5aa376ed8e1be6 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['faiVariable'];
- $new_dn ='cn='.$baseobject->cn.",".get_ou('faiVariableRDN').$this->parent->fai_release;
+ $new_dn ='cn='.$baseobject->cn.",".get_ou("faiVariable", "faiVariableRDN") .$this->parent->fai_release;
if ($this->dn != $new_dn && $this->dn != "new"){