summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ab0535e)
raw | patch | inline | side by side (parent: ab0535e)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 11 May 2010 05:09:58 +0000 (05:09 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 11 May 2010 05:09:58 +0000 (05:09 +0000) |
-It includes the source class now get_ou('core','userRDN');
-This makes it a lot easier to handle this values like properties.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18299 594d385d-05f5-0310-b6e9-bd551577e9d8
-This makes it a lot easier to handle this values like properties.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18299 594d385d-05f5-0310-b6e9-bd551577e9d8
89 files changed:
diff --git a/gosa-core/include/class_CopyPasteHandler.inc b/gosa-core/include/class_CopyPasteHandler.inc
index 5d83308418693cb9e1b529bd53d71660b8797922..587cdcc901c95143a375540d660294cf147e2e7b 100644 (file)
// Migrate objectgroups
$ogroups = get_sub_list("(&(objectClass=gosaGroupOfNames)(member=".LDAP::prepare4filter(LDAP::fix($src_dn))."))",
- "ogroups", array(get_ou("ogroupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
+ "ogroups", array(get_ou("group", "ogroupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
// Walk through all objectGroups
foreach($ogroups as $ogroup){
// Update roles
$roles = get_sub_list("(&(objectClass=organizationalRole)(roleOccupant=".LDAP::prepare4filter(LDAP::fix($src_dn))."))",
- "roles", array(get_ou("roleRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
+ "roles", array(get_ou("roleGeneric", "roleRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
// Walk through all roles
foreach($roles as $role){
$uid = $this->current['object']->uid;
$groups = get_sub_list("(&(objectClass=posixGroup)(memberUid={$suid}))",
- "groups",array(get_ou("groupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
+ "groups",array(get_ou("core", "groupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
// Walk through all POSIX groups
foreach($groups as $group){
index e50de7e22e022610ba36d91feb7e65cc632abcb2..314867e2da3fa9ae123df7ea5a69839c2ad58e66 100644 (file)
*/
function getShareList($listboxEntry = false)
{
- $tmp = get_sub_list("(&(objectClass=goShareServer)(goExportEntry=*))","server",get_ou("serverRDN"),
+ $tmp = get_sub_list("(&(objectClass=goShareServer)(goExportEntry=*))","server",get_ou("servgeneric", "serverRDN"),
$this->current['BASE'],array("goExportEntry","cn"), GL_NONE);
$return =array();
foreach($tmp as $entry){
$ui = get_userinfo();
$base = $config->current['BASE'];
$res= get_sub_list("(&(objectClass=goShareServer)(goExportEntry=*))", "server",
- get_ou("serverRDN"), $base,array("goExportEntry","cn"),GL_NONE | GL_NO_ACL_CHECK);
+ get_ou("servgeneric", "serverRDN"), $base,array("goExportEntry","cn"),GL_NONE | GL_NO_ACL_CHECK);
foreach($res as $entry){
index 1b45db134f9d88a81b8c7421af14293805132468..612a6999e2714a2ba3e0a90e906f7aa546b6c99c 100644 (file)
// Migrate objectgroups if needed
$ogroups = get_sub_list("(&(objectClass=gosaGroupOfNames)(member=".LDAP::prepare4filter(LDAP::fix($src_dn))."))",
- "ogroups", array(get_ou("ogroupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
+ "ogroups", array(get_ou("group", "ogroupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
// Walk through all objectGroups
foreach($ogroups as $ogroup){
}
// Migrate rfc groups if needed
- $groups = get_sub_list("(&(objectClass=posixGroup)(member=".LDAP::prepare4filter(LDAP::fix($src_dn))."))","groups", array(get_ou("groupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
+ $groups = get_sub_list("(&(objectClass=posixGroup)(member=".LDAP::prepare4filter(LDAP::fix($src_dn))."))","groups", array(get_ou("core", "groupRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
// Walk through all POSIX groups
foreach($groups as $group){
}
/* Update roles to use the new entry dn */
- $roles = get_sub_list("(&(objectClass=organizationalRole)(roleOccupant=".LDAP::prepare4filter(LDAP::fix($src_dn))."))","roles", array(get_ou("roleRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
+ $roles = get_sub_list("(&(objectClass=organizationalRole)(roleOccupant=".LDAP::prepare4filter(LDAP::fix($src_dn))."))","roles", array(get_ou("roleGeneric", "roleRDN")),$this->config->current['BASE'],array("dn"), GL_SUBSEARCH | GL_NO_ACL_CHECK);
// Walk through all roles
foreach($roles as $role){
index e7637663a920f936934e2ef2f586673fb0eddfd5..b66953840fe6f84100c9e3928942e4b598e1f7cd 100644 (file)
* Example:
* \code
* # Determine LDAP base where systems are stored
- * $base = get_ou('systemRDN') . $this->config->current['BASE'];
+ * $base = get_ou("systemManagement", "systemRDN") . $this->config->current['BASE'];
* $ldap->cd($base);
* \endcode
* */
* */
function get_people_ou()
{
- return (get_ou("userRDN"));
+ return (get_ou("core", "userRDN"));
}
*/
function get_groups_ou()
{
- return (get_ou("groupRDN"));
+ return (get_ou("core", "groupRDN"));
}
*/
function get_winstations_ou()
{
- return (get_ou("sambaMachineAccountRDN"));
+ return (get_ou("wingeneric", "sambaMachineAccountRDN"));
}
diff --git a/gosa-core/plugins/admin/acl/class_aclManagement.inc b/gosa-core/plugins/admin/acl/class_aclManagement.inc
index 35151da1edd56fda344ef41f848101898873dfec..6c931dfd471bac7fd5157161d4e13bbb48920d21 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("aclRoleRDN")); // ACLs are attached to department containers
+ $this->storagePoints = array(get_ou("aclrole", "aclRoleRDN")); // ACLs are attached to department containers
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/acl/tabs_acl_role.inc b/gosa-core/plugins/admin/acl/tabs_acl_role.inc
index 28be2338567e20491201b33fb37ac71e510fe6ae..faa8214da81e2bdc3d32bf05e4dd6f591f973eb0 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
- $new_dn= 'cn='.$baseobject->cn.",".get_ou('aclRoleRDN').$baseobject->base;
+ $new_dn= 'cn='.$baseobject->cn.",".get_ou("aclrole", "aclRoleRDN").$baseobject->base;
if ($this->dn != $new_dn){
diff --git a/gosa-core/plugins/admin/groups/class_groupManagement.inc b/gosa-core/plugins/admin/groups/class_groupManagement.inc
index 70ad9abbd4b6b3dd68c123649325875df5ae3115..41fa63a3bed1ddbe094390059dd6adbf73e99ce5 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("groupRDN"));
+ $this->storagePoints = array(get_ou("core", "groupRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/groups/singleUserSelect/class_singleUserSelect.inc b/gosa-core/plugins/admin/groups/singleUserSelect/class_singleUserSelect.inc
index f17008ce81bdfd921cd408679ecc938c46adbd1e..5133828c80c1269c07efe49f46ac93a1a47dcdb0 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("userRDN"));
+ $this->storagePoints = array(get_ou("core", "userRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/groups/userGroupSelect/class_userGroupSelect.inc b/gosa-core/plugins/admin/groups/userGroupSelect/class_userGroupSelect.inc
index 1a76fac6055a41868815d37ea5b602a9da813405..cedf4f71b1c4c734af3a736450c0b605de4338dc 100644 (file)
{
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("userRDN"), get_ou("groupRDN"));
+ $this->storagePoints = array(get_ou("core", "userRDN"), get_ou("core", "groupRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/groups/userSelect/class_userSelect.inc b/gosa-core/plugins/admin/groups/userSelect/class_userSelect.inc
index f5480b9d2b3f57bd0d2c1a949b48125f8dcf9ade..b52436495486205e62a14e664a9050a91e9e569b 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("userRDN"));
+ $this->storagePoints = array(get_ou("core", "userRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/ogroups/class_ogroup.inc b/gosa-core/plugins/admin/ogroups/class_ogroup.inc
index 97af881672e44db8ef933f6a2059451e4b08b7b0..ee3496bcb86d2d1bcc5a5f86c31169bd03c80a5b 100644 (file)
$ui = get_userinfo();
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
} else {
- $this->base= preg_replace("/^[^,]+,".preg_quote(get_ou("ogroupRDN"), '/')."/i","",$this->dn);
+ $this->base= preg_replace("/^[^,]+,".preg_quote(get_ou("group", "ogroupRDN"), '/')."/i","",$this->dn);
}
/* Detect all workstations, which are already assigned to an object group
"departments" => array("OBJ"=>"department", "CLASS"=>"gosaDepartment" ,
"DN"=> "" ,"ACL" => "department"),
"servers" => array("OBJ"=>"servgeneric", "CLASS"=>"goServer" ,
- "DN"=> get_ou('serverRDN') ,"ACL" => "server"),
+ "DN"=> get_ou("servgeneric", "serverRDN") ,"ACL" => "server"),
"workstations" => array("OBJ"=>"workgeneric", "CLASS"=>"gotoWorkstation",
- "DN"=> get_ou('workstationRDN') ,"ACL" => "workstation"),
+ "DN"=> get_ou("workgeneric", "workstationRDN") ,"ACL" => "workstation"),
"winstations" => array("OBJ"=>"wingeneric", "CLASS"=>"opsiClient",
"DN"=> get_ou('SAMBAMACHINEACCOUNTRDN') ,"ACL" => "winstation"),
"terminals" => array("OBJ"=>"termgeneric", "CLASS"=>"gotoTerminal" ,
- "DN"=> get_ou('terminalRDN') ,"ACL" => "terminal"),
+ "DN"=> get_ou("termgeneric", "terminalRDN") ,"ACL" => "terminal"),
"printers" => array("OBJ"=>"printgeneric", "CLASS"=>"gotoPrinter" ,
- "DN"=> get_ou('printerRDN') ,"ACL" => "printer"),
+ "DN"=> get_ou("printgeneric", "printerRDN") ,"ACL" => "printer"),
"phones" => array("OBJ"=>"phoneGeneric", "CLASS"=>"goFonHardware" ,
- "DN"=> get_ou('phoneRDN') ,"ACL" => "phone"));
+ "DN"=> get_ou("phoneGeneric", "phoneRDN") ,"ACL" => "phone"));
/* Allow searching for applications, if we are not using release managed applications
*/
if(!$this->IsReleaseManagementActivated()){
$p_f[ "applications"] = array("OBJ"=>"application", "CLASS"=>"gosaApplication",
- "DN"=> get_ou('applicationRDN') ,"ACL" => "application");
+ "DN"=> get_ou("application", "applicationRDN") ,"ACL" => "application");
}
/*###########
/* Permissions for that base? */
if ($this->base != ""){
- $new_dn= 'cn='.$this->cn.','.get_ou('ogroupRDN').$this->base;
+ $new_dn= 'cn='.$this->cn.','.get_ou("group", "ogroupRDN").$this->base;
} else {
$new_dn= $this->dn;
}
/* New accounts need proper 'dn', propagate it to remaining objects */
if ($this->dn == 'new'){
- $this->dn= 'cn='.$this->cn.','.get_ou('ogroupRDN').$this->base;
+ $this->dn= 'cn='.$this->cn.','.get_ou("group", "ogroupRDN").$this->base;
}
/* Save data. Using 'modify' implies that the entry is already present, use 'add' for
diff --git a/gosa-core/plugins/admin/ogroups/class_ogroupManagement.inc b/gosa-core/plugins/admin/ogroups/class_ogroupManagement.inc
index 54be3f263455f80ed83332a7f93c1be39feaaf11..d1c6cfa2e3550ccc8aa35a9760d9437fa2f38915 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("ogroupRDN"));
+ $this->storagePoints = array(get_ou("group", "ogroupRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/ogroups/objectSelect/class_objectSelect.inc b/gosa-core/plugins/admin/ogroups/objectSelect/class_objectSelect.inc
index f406bd7f904ec8bf838c6e5790f6eb752b829712..e8a5abad5189dcc3204f53956b3a72221cfc78db 100644 (file)
$this->config = $config;
$this->ui = $ui;
$this->storagePoints = array(
- get_ou("userRDN"),
- get_ou("groupRDN"),
- get_ou("terminalRDN"),
- get_ou("workstationRDN"),
- get_ou("serverRDN"),
- get_ou("printerRDN"),
- get_ou("phoneRDN"));
+ get_ou("core", "userRDN"),
+ get_ou("core", "groupRDN"),
+ get_ou("termgeneric", "terminalRDN"),
+ get_ou("workgeneric", "workstationRDN"),
+ get_ou("servgeneric", "serverRDN"),
+ get_ou("printgeneric", "printerRDN"),
+ get_ou("phoneGeneric", "phoneRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/admin/ogroups/tabs_ogroups.inc b/gosa-core/plugins/admin/ogroups/tabs_ogroups.inc
index f7846ba3712157a700ac5057180e8598ef407352..a37b9b8acf1312bc54678a6becf2195c1843abf3 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
- $new_dn= 'cn='.$baseobject->cn.','.get_ou('ogroupRDN').$baseobject->base;
+ $new_dn= 'cn='.$baseobject->cn.','.get_ou("group", "ogroupRDN").$baseobject->base;
/* Move group? */
if (LDAP::fix($this->dn) != LDAP::fix($new_dn)){
}
if ($this->dn == "new"){
- $this->dn= 'cn='.$baseobject->cn.','.get_ou('ogroupRDN').$baseobject->base;
+ $this->dn= 'cn='.$baseobject->cn.','.get_ou("group", "ogroupRDN").$baseobject->base;
}
/* Only delete attributes if there are members left */
diff --git a/gosa-core/plugins/admin/users/class_userManagement.inc b/gosa-core/plugins/admin/users/class_userManagement.inc
index f3a5429388d634da07909d8729ff621a2bd82434..d451a9aa31e5819a00f4d33f52b6d05df7084dba 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("userRDN"));
+ $this->storagePoints = array(get_ou("core", "userRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/personal/posix/groupSelect/class_groupSelect.inc b/gosa-core/plugins/personal/posix/groupSelect/class_groupSelect.inc
index a44296cf150d59af914024c8259075e4384ba6a7..b47d517d7adc6ee1d43ff4b2123571040788fd51 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("groupRDN"));
+ $this->storagePoints = array(get_ou("core", "groupRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-core/plugins/personal/posix/trustSelect/class_trustSelect.inc b/gosa-core/plugins/personal/posix/trustSelect/class_trustSelect.inc
index 9b449a81c61ef477867736bacfdb05c21fb41eb8..b2ef0b6123118a4d6579c19185d68bb44d89e3d9 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("workstationRDN"),get_ou("terminalRDN"),get_ou("serverRDN"),);
+ $this->storagePoints = array(get_ou("workgeneric", "workstationRDN"),get_ou("termgeneric", "terminalRDN"),get_ou("servgeneric", "serverRDN"),);
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/dns/admin/systems/services/dns/class_DNS.inc b/gosa-plugins/dns/admin/systems/services/dns/class_DNS.inc
index ec5ce83c8d2ec963c6d31ad3a5815d534f0b4237..73f07459dbf767dc71d068f8bd740bc1d99d51b6 100644 (file)
$ret = array();
$ldap = $config->get_ldap_link();
- $tmp = get_sub_list("(&(objectClass=dNSZone)(sOARecord=*))","",get_ou("serverRDN"),
+ $tmp = get_sub_list("(&(objectClass=dNSZone)(sOARecord=*))","",get_ou("servgeneric", "serverRDN"),
$config->current['BASE'],array("zoneName"),GL_NO_ACL_CHECK | GL_SUBSEARCH);
foreach($tmp as $at){
diff --git a/gosa-plugins/fai/admin/fai/class_faiHook.inc b/gosa-plugins/fai/admin/fai/class_faiHook.inc
index f0c0a6d0140d5df83ed4490cd1bb1c5bb22b3105..d0e151712b77e0dcdf7a0194974dfbb8d25a94df 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('faiBaseRDN').$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..9041bb00d7d80a695e4d19e56db41f2c77c7945f 100644 (file)
$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("faiPartitionTable", "faiPartitionRDN"),
+ get_ou("faiPackage", "faiPackageRDN"),
+ get_ou("faiScript", "faiScriptRDN"),
+ get_ou("faiVariable", "faiVariableRDN"),
+ get_ou("faiHook", "faiHookRDN"),
+ get_ou("faiProfile", "faiProfileRDN"),
+ get_ou("faiTemplate", "faiTemplateRDN"));
// 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('faiBaseRDN'), '/').'/i', ','.get_ou("application", "applicationRDN"), $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('faiBaseRDN'), '/').'/i', ','.get_ou("mimetype", "mimetypeRDN"), $bb));
$ldap->recursive_remove();
/* Search for all groups with configured application menus.
$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('faiBaseRDN'), '/')."/i",get_ou("application", "applicationRDN"),$baseToUse);
+ $appdst = preg_replace("/".preg_quote(get_ou('faiBaseRDN'), '/')."/i",get_ou("application", "applicationRDN"),"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('faiBaseRDN'), '/')."/i",get_ou("mimetype", "mimetypeRDN"),$baseToUse);
+ $mimedst = preg_replace("/".preg_quote(get_ou('faiBaseRDN'), '/')."/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..28631c25f52a513ad988771311d7fa0986b74360 100644 (file)
*/
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('faiBaseRDN').$release;
$res = faiManagement::check_class_name("FAIpackageList",$this->cn,$new_dn);
if(isset($res[$this->cn])){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc b/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc
index 9e4c14deaaa3f38a14aaf20ec8475666a867cc69..6f3630e6e54c2b8768198af0294f2bce6530a997 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('faiBaseRDN').$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..80908909fc2a86f7aa1b4c2757b555f07bda8be1 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('faiBaseRDN').$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..8575e6f8fadb03e75c9a05c87191e628ee338a56 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('faiBaseRDN').$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..d6991f49c843fe7ee25ae491735c66cde4299a15 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("faiScript", "faiScriptRDN")) ,
+ "FAIhook" => array( "Image" =>"plugins/fai/images/fai_hook.png" , "Name"=>_("Hooks") ,"Tree" =>get_ou("faiHook", "faiHookRDN")),
+ "FAIvariable" => array( "Image" =>"plugins/fai/images/fai_variable.png", "Name"=>_("Variables") ,"Tree" =>get_ou("faiVariable", "faiVariableRDN")) ,
+ "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("faiPartitionTable", "faiPartitionRDN")) ,
+ "FAIpackageList" => array( "Image" =>"plugins/fai/images/fai_packages.png", "Name"=>_("Package list") ,"Tree" =>get_ou("faiPackage", "faiPackageRDN")) ,
+ "FAIprofile" => array( "Image" =>"plugins/fai/images/fai_profile.png", "Name"=>_("Profiles") ,"Tree" =>get_ou("faiProfile", "faiProfileRDN")));
}
/* 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("faiProfile", "faiProfileRDN"), '/')."/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..b370dd6c9dcb53f3ff5d4d0976c1d31707aeb031 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('faiBaseRDN').$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..9de8ee3123c4a89b9aec27c663fe99f0028c945c 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('faiBaseRDN').$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..86f2e989b44f19929437b6c506a1dcb8e6c82a93 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("faiPartitionTable", "faiPartitionRDN") , "CHKBOX"=>"ShowPartitions" ,
"ACL" => "faiPartitionTable"),
- "FAIpackageList" => array("OU"=> get_ou('faiPackageRDN') , "CHKBOX"=>"ShowPackages" ,
+ "FAIpackageList" => array("OU"=> get_ou("faiPackage", "faiPackageRDN") , "CHKBOX"=>"ShowPackages" ,
"ACL" => "faiPackage"),
- "FAIscript" => array("OU"=> get_ou('faiScriptRDN') , "CHKBOX"=>"ShowScripts" ,
+ "FAIscript" => array("OU"=> get_ou("faiScript", "faiScriptRDN") , "CHKBOX"=>"ShowScripts" ,
"ACL" => "faiScript"),
- "FAIvariable" => array("OU"=> get_ou('faiVariableRDN') , "CHKBOX"=>"ShowVariables" ,
+ "FAIvariable" => array("OU"=> get_ou("faiVariable", "faiVariableRDN") , "CHKBOX"=>"ShowVariables" ,
"ACL" => "faiVariable"),
- "FAIhook" => array("OU"=> get_ou('faiHookRDN') , "CHKBOX"=>"ShowHooks" ,
+ "FAIhook" => array("OU"=> get_ou("faiHook", "faiHookRDN") , "CHKBOX"=>"ShowHooks" ,
"ACL" => "faiHook"),
- "FAIprofile" => array("OU"=> get_ou('faiProfileRDN') , "CHKBOX"=>"ShowProfiles" ,
+ "FAIprofile" => array("OU"=> get_ou("faiProfile", "faiProfileRDN") , "CHKBOX"=>"ShowProfiles" ,
"ACL" => "faiProfile"),
- "FAItemplate" => array("OU"=> get_ou('faiTemplateRDN') , "CHKBOX"=>"ShowTemplates" ,
+ "FAItemplate" => array("OU"=> get_ou("faiTemplate", "faiTemplateRDN") , "CHKBOX"=>"ShowTemplates" ,
"ACL" => "faiTemplate"));
index 40c997c767e8378f8b81c71c26c294a2683db3dc..a271f73ed13598d286ce4ebeb8f8ee1bd381211f 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..f3111f4a0221ca922a0fbfb3886e1d2ecc7792fc 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..706658d669a945978e453abdd01a5c85506b4031 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..ac147a50f36e7360bbcf0dd69c84153fc2bf7512 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..02e27c7b529f45d5a4352ac2624732acd3419863 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..6c5e41b7fa747d5cd46fb1603dba3a9986c8e442 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..dd38c1b7eb0c644dc5637103d03f6bca3dd41e81 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"){
diff --git a/gosa-plugins/gofax/gofax/blocklists/class_blocklistGeneric.inc b/gosa-plugins/gofax/gofax/blocklists/class_blocklistGeneric.inc
index 05c41436d11097d15e6f6c4038acf838356ca9cc..5683258e806dcbe618069ccdec3cbf24ee7141ea 100644 (file)
$this->base= dn2base($ui->dn);
}
} else {
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("faxBlocklistRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("blocklistGeneric", "faxBlocklistRDN"), '/')."/i", "", $this->dn);
}
$this->orig_base = $this->base;
}
if ($this->dn == 'new'){
$ldap= $this->config->get_ldap_link();
- $ldap->cd (get_ou('faxBlocklistRDN').$this->config->current["BASE"]);
+ $ldap->cd (get_ou("blocklistGeneric", "faxBlocklistRDN").$this->config->current["BASE"]);
$ldap->search ("(&(|(objectClass=goFaxSBlock)(objectClass=goFaxRBlock))(cn=".$this->cn."))", array("cn"));
if ($ldap->count() != 0){
$message[]= msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/gofax/gofax/blocklists/class_blocklistManagement.inc b/gosa-plugins/gofax/gofax/blocklists/class_blocklistManagement.inc
index 4f59ce256a576cf81bfeb69b187bd262cc5b2c09..3afc620ad639bc369fc5cc84c1cb77315a2acbd4 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("faxBlocklistRDN"));
+ $this->storagePoints = array(get_ou("blocklistGeneric", "faxBlocklistRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/gofax/gofax/blocklists/tabs_blocklist.inc b/gosa-plugins/gofax/gofax/blocklists/tabs_blocklist.inc
index 54a378674caab0e73b02d45936497184023e5f37..79c879ed67c57d2e0f800fd6400f5ffe156a2aa8 100644 (file)
$baseobject= $this->by_object['blocklistGeneric'];
/* Check for new 'dn', in order to propagate the 'dn' to all plugins */
- $new_dn= "cn=".$baseobject->cn.",".get_ou('faxBlocklistRDN').$baseobject->base;
+ $new_dn= "cn=".$baseobject->cn.",".get_ou("blocklistGeneric", "faxBlocklistRDN").$baseobject->base;
/* Move group? */
if ($this->dn != $new_dn){
diff --git a/gosa-plugins/gofax/gofax/faxaccount/faxNumberSelect/class_faxNumberSelect.inc b/gosa-plugins/gofax/gofax/faxaccount/faxNumberSelect/class_faxNumberSelect.inc
index f995d0d3f992cc8b6760ae39e5f1ea62663dda7a..ccac9544f7d489767e251f7311d16f147b053e9a 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("userRDN"));
+ $this->storagePoints = array(get_ou("core", "userRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/gofon/admin/systems/gofon/class_phoneGeneric.inc b/gosa-plugins/gofon/admin/systems/gofon/class_phoneGeneric.inc
index b5ef3d31801498a66566a5e77f7fe914b293d298..a3bfe73ef518bc234274e6de5f53ac76edb2465c 100644 (file)
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
$this->cn= "";
} else {
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("phoneRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("phoneGeneric", "phoneRDN"), '/')."/i", "", $this->dn);
}
if($this->goFonMSN != ""){
$message= plugin::check();
$message= array_merge($message, $this->netConfigDNS->check());
- $this->dn= "cn=".$this->cn.",".get_ou('phoneRDN').$this->base;
+ $this->dn= "cn=".$this->cn.",".get_ou("phoneGeneric", "phoneRDN").$this->base;
/* To check for valid ip*/
if($this->netConfigDNS->ipHostNumber == ""){
diff --git a/gosa-plugins/gofon/admin/systems/gofon/tabs_phone.inc b/gosa-plugins/gofon/admin/systems/gofon/tabs_phone.inc
index b8a85905814a36caa918fb90ac3754f0303f27bd..f18188b08e8fe8b23121530d6a6b3f086ac3bcc0 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
$baseobject= $this->by_object['phoneGeneric'];
- $this->dn= "cn=$baseobject->cn,".get_ou('phoneRDN').$baseobject->base;
+ $this->dn= "cn=$baseobject->cn,".get_ou("phoneGeneric", "phoneRDN").$baseobject->base;
$baseobject->dn= $this->dn;
foreach ($this->by_object as $key => $obj){
diff --git a/gosa-plugins/gofon/gofon/conference/class_phoneConferenceGeneric.inc b/gosa-plugins/gofon/gofon/conference/class_phoneConferenceGeneric.inc
index eb56f14a8085c659cc52998ad3970936cb9856cd..399a3aef8fe5e8ac341a34e397ea9a00633f4373 100644 (file)
} else {
/* Get base */
- $this->base = preg_replace ("/^[^,]+,".preg_quote(get_ou('phoneConferenceRDN'), '/')."/i","",$this->dn);;
+ $this->base = preg_replace ("/^[^,]+,".preg_quote(get_ou("conference", "phoneConferenceRDN"), '/')."/i","",$this->dn);;
}
$this->goFonConferenceOwner=$this->ui->dn;
if($this->old_cn != $this->cn || $this->base != $this->old_base){
$ldap = $this->config->get_ldap_link();
- $ldap->cd(get_ou('phoneConferenceRDN').$this->base);
+ $ldap->cd(get_ou("conference", "phoneConferenceRDN").$this->base);
$ldap->search("(&(objectClass=goFonConference)(cn=".$this->cn."))",array("cn"));
if($ldap->count()){
$message[] = msgPool::duplicated(_("Name"));
diff --git a/gosa-plugins/gofon/gofon/conference/class_phoneConferenceManagment.inc b/gosa-plugins/gofon/gofon/conference/class_phoneConferenceManagment.inc
index 113eb5075299b4fff6db363d301b589633718ed5..29867ddaeda8b9ef22a157b791e8441dce81f634 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("phoneConferenceRDN"));
+ $this->storagePoints = array(get_ou("conference", "phoneConferenceRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/gofon/gofon/conference/tabs_conference.inc b/gosa-plugins/gofon/gofon/conference/tabs_conference.inc
index 8d51b1f9bb95bde204288502fbf20838a6b38e59..35038a579067fe09e610f3679ee1524cdde21ade 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['conference'];
- $new_dn= 'cn='.$baseobject->cn.','.get_ou('phoneConferenceRDN').$baseobject->base;
+ $new_dn= 'cn='.$baseobject->cn.','.get_ou("conference", "phoneConferenceRDN").$baseobject->base;
if(strtolower($this->dn)==strtolower($new_dn)){
$this->dn=$new_dn;
diff --git a/gosa-plugins/gofon/gofon/macro/class_gofonMacro.inc b/gosa-plugins/gofon/gofon/macro/class_gofonMacro.inc
index fc9f8809da04442666d84ba95fc6249f5be56e24..63424cd41aabdbbc459c4108f6d03a39dc9d64c4 100644 (file)
}
} else {
$this->orig_cn=$this->cn;
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("phoneMacroRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("macro", "phoneMacroRDN"), '/')."/i", "", $this->dn);
}
/* Check server configurations
diff --git a/gosa-plugins/gofon/gofon/macro/class_gofonMacroManagement.inc b/gosa-plugins/gofon/gofon/macro/class_gofonMacroManagement.inc
index af074a93638c1701f22d204f350ee43859131b63..90f93733747ef1b83d12a7e08cb1e51d0bab17d6 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("phoneMacroRDN"));
+ $this->storagePoints = array(get_ou("macro", "phoneMacroRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/gofon/gofon/macro/tabs_macros.inc b/gosa-plugins/gofon/gofon/macro/tabs_macros.inc
index f874015e40b23674dff177b529105e059e96bf49..e797fb8812d64d7b7f11044178737310f9b19475 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
- $new_dn= "cn=".$baseobject->cn.",".get_ou('phoneMacroRDN').$baseobject->base;
+ $new_dn= "cn=".$baseobject->cn.",".get_ou("macro", "phoneMacroRDN").$baseobject->base;
/* Move group? */
if ($this->dn != $new_dn){
diff --git a/gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc b/gosa-plugins/gofon/gofon/phoneaccount/class_phoneAccount.inc
index 672f51c391c19ad22c5ce8c52b42587a5b2d0fbf..c12bc487f17ddf62cd65544d5e9bb3f34fcd8d91 100644 (file)
/* Get available phone hardware
* Search for all available phone hardware
*/
- $tmp = get_sub_list("(objectClass=goFonHardware)","phone",array(get_ou("phoneRDN")),
+ $tmp = get_sub_list("(objectClass=goFonHardware)","phone",array(get_ou("phoneGeneric", "phoneRDN")),
$this->config->current['BASE'],array("cn","description"), GL_SUBSEARCH);
foreach($tmp as $attrs){
$cn= $attrs['cn'][0];
*/
$deps_a = array(
get_people_ou(),
- get_ou("ogroupRDN"),
- get_ou("serverRDN"),
- get_ou("terminalRDN"),
- get_ou("workstationRDN"),
- get_ou("printerRDN"),
- get_ou("componentRDN"),
- get_ou("phoneRDN"));
+ get_ou("group", "ogroupRDN"),
+ get_ou("servgeneric", "serverRDN"),
+ get_ou("termgeneric", "terminalRDN"),
+ get_ou("workgeneric", "workstationRDN"),
+ get_ou("printgeneric", "printerRDN"),
+ get_ou("componentGeneric", "componentRDN"),
+ get_ou("phoneGeneric", "phoneRDN"));
$tmp = get_sub_list("(goFonHardware=*)","phone",$deps_a,$this->config->current['BASE'],
array('cn','dn','goFonHardware'),GL_SUBSEARCH);
* Search for all Macros that are visible and create
* an array with name and parameters
*/
- $tmp = get_sub_list("(&(objectClass=goFonMacro)(goFonMacroVisible=1))","gofonmacro",array(get_ou("phoneMacroRDN")),
+ $tmp = get_sub_list("(&(objectClass=goFonMacro)(goFonMacroVisible=1))","gofonmacro",array(get_ou("macro", "phoneMacroRDN")),
$this->config->current['BASE'],array("displayName","goFonMacroParameter","dn","cn"), GL_NO_ACL_CHECK | GL_SUBSEARCH );
diff --git a/gosa-plugins/goto/addons/goto/events/class_EventAddSystemDialog.inc b/gosa-plugins/goto/addons/goto/events/class_EventAddSystemDialog.inc
index f7ba9ec8e30a0839dbd90c7f9e12fde1282e4eb6..cb20ebed31432bf7818d1d17500b16511c41d008 100644 (file)
$this->config = $config;
$this->ui = $ui;
$this->storagePoints = array(
- get_ou("serverRDN"),
- get_ou("workstationRDN"),
- get_ou("ogroupRDN"),
- get_ou('terminalRDN'));
+ get_ou("servgeneric", "serverRDN"),
+ get_ou("workgeneric", "workstationRDN"),
+ get_ou("group", "ogroupRDN"),
+ get_ou("termgeneric", "terminalRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/goto/addons/goto/events/class_EventAddUserDialog.inc b/gosa-plugins/goto/addons/goto/events/class_EventAddUserDialog.inc
index 0649761c88422e0a946242bf1f8adc21979a691f..85aac618500b571e33389c1a0023e4759a3c71a9 100644 (file)
$this->config = $config;
$this->ui = $ui;
$this->storagePoints = array(
- get_ou("userRDN"),
- get_ou("groupRDN"));
+ get_ou("core", "userRDN"),
+ get_ou("core", "groupRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/goto/admin/applications/class_applicationGeneric.inc b/gosa-plugins/goto/admin/applications/class_applicationGeneric.inc
index bf11b1f7aba247fc43dd11fe70a9124912a42532..84ac3d16a171eb9681e9cd0ce48972e09d96016f 100644 (file)
$this->base= dn2base($ui->dn);
}
} else {
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou('applicationRDN'), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("application", "applicationRDN"), '/')."/i", "", $this->dn);
}
$this->orig_cn = $this->cn;
function remove_from_parent()
{
/* Parse release out of object dn */
- $release = preg_replace("/".preg_quote(get_ou("applicationRDN").$this->base, '/')."$/i","",$this->dn);
+ $release = preg_replace("/".preg_quote(get_ou("application", "applicationRDN").$this->base, '/')."$/i","",$this->dn);
$release = preg_replace("/^cn=[^,]+,/","",$release);
/* Get a list of all groups
/* Permissions for that base? */
if ($this->base != ""){
- $new_dn= "cn=".$this->cn.",".get_ou('applicationRDN').$this->base;
+ $new_dn= "cn=".$this->cn.",".get_ou("application", "applicationRDN").$this->base;
} else {
$new_dn= $this->dn;
}
if($this->is_release()){
$base = $this->parent->parent->app_release;
}else{
- $base = get_ou('applicationRDN').$this->base;
+ $base = get_ou("application", "applicationRDN").$this->base;
}
$ldap->ls("(&(objectClass=gosaApplication)(cn=".$this->cn."))",$base,array("cn"));
diff --git a/gosa-plugins/goto/admin/applications/class_applicationManagement.inc b/gosa-plugins/goto/admin/applications/class_applicationManagement.inc
index 3cd74a415ee67d604dae69a7711c92027591ab19..d468b4c2e813e42435088ca10e9ec6b865f1f1db 100644 (file)
{
$this->config = $config;
$this->ui = $ui;
- $this->app_base = get_ou('applicationRDN').$this->config->current['BASE'];
- $this->app_release = get_ou('applicationRDN').$this->config->current['BASE'];
+ $this->app_base = get_ou("application", "applicationRDN").$this->config->current['BASE'];
+ $this->app_release = get_ou("application", "applicationRDN").$this->config->current['BASE'];
if($this->IsReleaseManagementActivated()){
$filter_xml = "application-filter-release.xml";
}else{
$filter_xml = "application-filter.xml";
$list_xml = "application-list.xml";
- $this->storagePoints= array(get_ou("applicationRDN"));
+ $this->storagePoints= array(get_ou("application", "applicationRDN"));
}
// Build filter
diff --git a/gosa-plugins/goto/admin/applications/tabs_application.inc b/gosa-plugins/goto/admin/applications/tabs_application.inc
index bf7a311f27bc76114d6e7572b4b39ee82ffbf475..eea2a1a45200a357e9bdaa42d4326d9ae17ff515 100644 (file)
if($baseobject->parent->parent->IsReleaseManagementActivated()){
$new_dn= "cn=".$baseobject->cn.",".$baseobject->parent->parent->app_release;
}else{
- $new_dn= "cn=".$baseobject->cn.",".get_ou('applicationRDN').$baseobject->base;
+ $new_dn= "cn=".$baseobject->cn.",".get_ou("application", "applicationRDN").$baseobject->base;
}
// Do we have to move the object?
diff --git a/gosa-plugins/goto/admin/devices/class_deviceGeneric.inc b/gosa-plugins/goto/admin/devices/class_deviceGeneric.inc
index 037963de6088bed57a04b39341881eeb0f984fd5..693fe19f957217b80d22b50ee63cc72b4817a55b 100644 (file)
$this->base= dn2base($ui->dn);
}
} else {
- $this->base =preg_replace ("/^[^,]+,".preg_quote(get_ou('deviceRDN'), '/')."/i","",$this->dn);
+ $this->base =preg_replace ("/^[^,]+,".preg_quote(get_ou("deviceGeneric", "deviceRDN"), '/')."/i","",$this->dn);
}
$this->orig_base = $this->base;
$this->orig_dn = $this->dn;
diff --git a/gosa-plugins/goto/admin/devices/class_deviceManagement.inc b/gosa-plugins/goto/admin/devices/class_deviceManagement.inc
index 7ec0081b59cd2ce27ed401237dec1bd7135aea24..133537b34bfbeb9e616ceb6735e6145aaf27754c 100644 (file)
$filter_xml = "device-filter.xml";
$list_xml = "device-list.xml";
- $this->storagePoints= array(get_ou("deviceRDN"));
+ $this->storagePoints= array(get_ou("deviceGeneric", "deviceRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/goto/admin/devices/tabs_devices.inc b/gosa-plugins/goto/admin/devices/tabs_devices.inc
index e2b49799385024dc60971ddce09f271dac46b669..518fe8469ca755c0dc3fef872d30a5158d3dfc0a 100644 (file)
function save($ignore_account= FALSE)
{
$baseobject= $this->by_object['deviceGeneric'];
- $new_dn= "cn=".$baseobject->cn.",".get_ou('deviceRDN').$baseobject->base;
+ $new_dn= "cn=".$baseobject->cn.",".get_ou("deviceGeneric", "deviceRDN").$baseobject->base;
/* Move group? */
if ($this->dn != $new_dn){
diff --git a/gosa-plugins/goto/admin/groups/apps/class_groupApplication.inc b/gosa-plugins/goto/admin/groups/apps/class_groupApplication.inc
index 2f6e60a2ca39c6a2ee1646ad86604df75f4714d6..56fc4ace693aa00ccb208538b19c602cabc67136 100644 (file)
*/
function getReleases()
{
- $ret =array("/" => array("name" => "/", "found" => TRUE , "parts" => array(),"suffix" => get_ou('applicationRDN')));
+ $ret =array("/" => array("name" => "/", "found" => TRUE , "parts" => array(),"suffix" => get_ou("application", "applicationRDN")));
if($this->enableReleaseManagement){
/* Only display those releases that we are able to read
*/
- $dn = get_ou("applicationRDN").$this->config->current['BASE'];
+ $dn = get_ou("application", "applicationRDN").$this->config->current['BASE'];
$filter = "(&(objectClass=organizationalUnit)(objectClass=FAIbranch))";
$res = get_sub_list($filter,array("application","fai"),
- array(get_ou("applicationRDN"),get_ou("faiBaseRDN")),$dn, array("ou","FAIstate"), GL_SUBSEARCH);
+ array(get_ou("application", "applicationRDN"),get_ou("faiBaseRDN")),$dn, array("ou","FAIstate"), GL_SUBSEARCH);
/* Go through all departments and check which department is a valid
department release.
*/
foreach($res as $attrs){
- if(preg_match("/".get_ou('applicationRDN')."/i",$attrs['dn'])){
+ if(preg_match("/".get_ou("application", "applicationRDN")."/i",$attrs['dn'])){
/* Parse all returned departments dns into a useable type.
(ou=1.0.0,ou=halut,ou=apps ==> halue/1.0.0)
*/
- $bb = preg_replace("/".preg_quote(get_ou('applicationRDN'), '/').".*/i","",$attrs['dn']);
+ $bb = preg_replace("/".preg_quote(get_ou("application", "applicationRDN"), '/').".*/i","",$attrs['dn']);
$parts = array_reverse(explode("ou=",$bb));
$str ="";
"found" => $found,
"FAIstate" => $FAIstate,
"dn" => $attrs['dn'],
- "parts" => $parts,"suffix" => $bb.get_ou('applicationRDN'));
+ "parts" => $parts,"suffix" => $bb.get_ou("application", "applicationRDN"));
}
}
}
$used_apps = $this->_get_used_entry_name();
foreach($this->apps as $key => $app){
if(in_array($app['cn'][0],$used_apps)) continue;
- if(!preg_match("/".get_ou('applicationRDN').preg_quote($this->curbase, '/')."$/",$app['dn'])){
+ if(!preg_match("/".get_ou("application", "applicationRDN").preg_quote($this->curbase, '/')."$/",$app['dn'])){
continue;
}
diff --git a/gosa-plugins/goto/admin/mimetypes/class_mimetypeGeneric.inc b/gosa-plugins/goto/admin/mimetypes/class_mimetypeGeneric.inc
index 2b85b69d571e07259a05787bf6db7fbaa40639ec..fcedd704353da3b2a2444dbe95f793e136e59573 100644 (file)
$this->base= dn2base($ui->dn);
}
} else {
- $this->base= preg_replace ("/^.*,".preg_quote(get_ou("mimetypeRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^.*,".preg_quote(get_ou("mimetype", "mimetypeRDN"), '/')."/i", "", $this->dn);
}
/* Get icon data */
if($this->is_release()){
$base = $this->parent->parent->mime_release;
}else{
- $base = get_ou("mimetypeRDN").$this->base;
+ $base = get_ou("mimetype", "mimetypeRDN").$this->base;
}
$ldap->ls("(&(objectClass=gotoMimeType)(cn=".$this->cn."))",$base,array("cn"));
diff --git a/gosa-plugins/goto/admin/mimetypes/class_mimetypeManagement.inc b/gosa-plugins/goto/admin/mimetypes/class_mimetypeManagement.inc
index 5c287006c39be6886bd64a9ee475872ee97f47be..fa0bb955df57ab7dba8739b252cb2ea8aa8db2cb 100644 (file)
{
$this->config = $config;
$this->ui = $ui;
- $this->mime_base = get_ou('mimetypeRDN').$this->config->current['BASE'];
- $this->mime_release = get_ou('mimetypeRDN').$this->config->current['BASE'];
+ $this->mime_base = get_ou("mimetype", "mimetypeRDN").$this->config->current['BASE'];
+ $this->mime_release = get_ou("mimetype", "mimetypeRDN").$this->config->current['BASE'];
if($this->IsReleaseManagementActivated()){
$filter_xml = "mimetype-filter-release.xml";
}else{
$filter_xml = "mimetype-filter.xml";
$list_xml = "mimetype-list.xml";
- $this->storagePoints= array(get_ou("mimetypeRDN"));
+ $this->storagePoints= array(get_ou("mimetype", "mimetypeRDN"));
}
// Build filter
diff --git a/gosa-plugins/goto/admin/mimetypes/tabs_mimetypes.inc b/gosa-plugins/goto/admin/mimetypes/tabs_mimetypes.inc
index dacda448687497bbe79d4925737e05ab1c7a10cd..6244c0623acf1eff7ae4ac103cea62d007f70b9a 100644 (file)
if($this->parent->IsReleaseManagementActivated()){
$new_dn= "cn=".$baseobject->cn.",".$this->parent->mime_release;
}else{
- $new_dn= "cn=".$baseobject->cn.",".get_ou('mimetypeRDN').$baseobject->base;
+ $new_dn= "cn=".$baseobject->cn.",".get_ou("mimetype", "mimetypeRDN").$baseobject->base;
}
/* Move group? */
diff --git a/gosa-plugins/goto/admin/systems/goto/class_printGeneric.inc b/gosa-plugins/goto/admin/systems/goto/class_printGeneric.inc
index c420b2f1d5d93f893d7002ac93fa0271c5a46c02..7bd5622c199213c569061050a4d1c425a09dcac1 100644 (file)
/* Update dn, to ensure storing as printer instead of WS / terminal */
if(preg_match("/Terminal/i",$this->BelongsTo) || preg_match("/TerminalTemplate/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('terminalRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("termgeneric", "terminalRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
if(preg_match("/Workstation/i",$this->BelongsTo) || preg_match("/WorkstationTemplate/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('workstationRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("workgeneric", "workstationRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
$this->orig_dn = $this->dn;
} else {
/* Set base and check if the extracted base exists */
- if(preg_match("/".preg_quote(get_ou('systemIncomingRDN'), '/')."/i",$this->dn)){
- $this->base= preg_replace("/".preg_quote(get_ou('systemIncomingRDN'), '/')."/i","",dn2base($this->dn));
+ if(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i",$this->dn)){
+ $this->base= preg_replace("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i","",dn2base($this->dn));
}else{
- $this->base= preg_replace("/".preg_quote(get_ou('printerRDN'), '/')."/i","",dn2base($this->dn));
+ $this->base= preg_replace("/".preg_quote(get_ou("printgeneric", "printerRDN"), '/')."/i","",dn2base($this->dn));
}
if(!isset($this->config->idepartments[$this->base])){
/* Update dn, to ensure storing as printer instead of WS / terminal
*/
if(preg_match("/terminal/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('terminalRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("termgeneric", "terminalRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
if(preg_match("/workstation/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('workstationRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("workgeneric", "workstationRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
/* Detect if this is a valid printer account;
/* Update dn, to ensure storing as printer instead of WS / terminal
*/
if(preg_match("/terminal/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('terminalRDN'), '/').",/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("termgeneric", "terminalRDN"), '/').",/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
if(preg_match("/workstation/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('workstationRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("workgeneric", "workstationRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
/* Check if this dn points to a printer, to avoid deleting something else */
}
}
- $dn= "cn=".$this->cn.get_ou('printerRDN').",".$this->base;
+ $dn= "cn=".$this->cn.get_ou("printgeneric", "printerRDN").",".$this->base;
/* must: cn */
if(($this->BelongsTo == "Printer") && $this->cn == ""){
if (($this->orig_dn != $dn)&&( preg_match("/printer/i",$this->BelongsTo))){
$ldap= $this->config->get_ldap_link();
$ldap->cd ($this->base);
- $ldap->ls("(cn=".$this->cn.")",get_ou('printerRDN').$this->base, array("cn"));
+ $ldap->ls("(cn=".$this->cn.")",get_ou("printgeneric", "printerRDN").$this->base, array("cn"));
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
if(preg_match("/cn=dhcp,/",$attrs['dn'])){
/* Update dn, to ensure storing as printer instead of WS / terminal
*/
if(preg_match("/terminal/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('terminalRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("termgeneric", "terminalRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
if(preg_match("/workstation/i",$this->BelongsTo)){
- $this->dn= preg_replace("/".preg_quote(get_ou('workstationRDN'), '/')."/i",get_ou('printerRDN'),$this->dn);
+ $this->dn= preg_replace("/".preg_quote(get_ou("workgeneric", "workstationRDN"), '/')."/i",get_ou("printgeneric", "printerRDN"),$this->dn);
}
if(!$this->is_account) return;
}
/* Ensure to create a new object */
- if(preg_match("/".preg_quote(get_ou('systemIncomingRDN'), '/')."/i",$this->orig_dn)){
+ if(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i",$this->orig_dn)){
$this->orig_dn = "new";
}
diff --git a/gosa-plugins/goto/admin/systems/goto/class_terminalGeneric.inc b/gosa-plugins/goto/admin/systems/goto/class_terminalGeneric.inc
index 6564b864c05b8af0695e334be69ae61e635bf09b..add8d2ba7ffce7f278db9e208cccf05945e92bcd 100644 (file)
if ($this->dn == "new"){
$ui= get_userinfo();
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
- } elseif(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", $this->dn)){
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", "", $this->dn);
+ } elseif(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $this->dn)){
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", "", $this->dn);
} else {
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("terminalRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("termgeneric", "terminalRDN"), '/')."/i", "", $this->dn);
}
/* Create an array of all Syslog servers */
}
/* Permissions for that base? */
- $this->dn= "cn=".$this->cn.",".get_ou('terminalRDN').$this->base;
+ $this->dn= "cn=".$this->cn.",".get_ou("termgeneric", "terminalRDN").$this->base;
if ($this->cn == ""){
$message[]= msgPool::required(_("Name"));
}
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
- if (preg_match("/cn=dhcp,/",$attrs['dn']) || preg_match ("/,".preg_quote(get_ou('systemIncomingRDN'), '/')."/i", $ldap->getDN())){
+ if (preg_match("/cn=dhcp,/",$attrs['dn']) || preg_match ("/,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $ldap->getDN())){
continue;
} else {
if ($attrs['dn'] != $this->orig_dn){
$ldap= $this->config->get_ldap_link();
/* Strip relevant part from dn, keep trailing ',' */
- $tmp= preg_replace("/^cn=[^,]+,".preg_quote(get_ou('terminalRDN'), '/')."/i", "", $this->dn);
+ $tmp= preg_replace("/^cn=[^,]+,".preg_quote(get_ou("termgeneric", "terminalRDN"), '/')."/i", "", $this->dn);
$tmp= preg_replace("/".$this->config->current['BASE']."$/i", "", $tmp);
/* Walk from top to base and try to load default values for
while (TRUE){
$tmp= preg_replace ("/^[^,]+,/", "", $tmp);
- $ldap->cat("cn=default,".get_ou('terminalRDN').$tmp.
+ $ldap->cat("cn=default,".get_ou("termgeneric", "terminalRDN").$tmp.
$this->config->current['BASE'], array('gotoTerminalPath'));
$attrs= $ldap->fetch();
if (isset($attrs['gotoTerminalPath'])){
diff --git a/gosa-plugins/goto/admin/systems/goto/class_terminalService.inc b/gosa-plugins/goto/admin/systems/goto/class_terminalService.inc
index 28846fd5049d62352e1918fbde38063deb774000..9d1f4ed7497877e9935e09ddacbe18a40f2b5170 100644 (file)
/* Load phone hardware list
*/
- $tmp = get_sub_list("(objectClass=goFonHardware)","",array(get_ou("phoneRDN")),
+ $tmp = get_sub_list("(objectClass=goFonHardware)","",array(get_ou("phoneGeneric", "phoneRDN")),
$this->config->current['BASE'],array("cn","description"), GL_NO_ACL_CHECK);
foreach($tmp as $attrs){
$cn= $attrs['cn'][0];
*/
$deps_a = array(
get_people_ou(),
- get_ou("ogroupRDN"),
- get_ou("serverRDN"),
- get_ou("terminalRDN"),
- get_ou("workstationRDN"),
- get_ou("printerRDN"),
- get_ou("componentRDN"),
- get_ou("phoneRDN"));
+ get_ou("group", "ogroupRDN"),
+ get_ou("servgeneric", "serverRDN"),
+ get_ou("termgeneric", "terminalRDN"),
+ get_ou("workgeneric", "workstationRDN"),
+ get_ou("printgeneric", "printerRDN"),
+ get_ou("componentGeneric", "componentRDN"),
+ get_ou("phoneGeneric", "phoneRDN"));
$tmp = get_sub_list("(goFonHardware=*)","",$deps_a,$this->config->current['BASE'],
array('cn','dn','goFonHardware'),GL_NO_ACL_CHECK);
*/
$p = $this->parent->by_object['ogroup'];
foreach($p->memberList as $dn => $obj){
- if(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/",$dn)) continue;
+ if(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/",$dn)) continue;
if(isset($p->objcache[$dn]['macAddress']) && !empty($p->objcache[$dn]['macAddress'])){
$macs[] = $p->objcache[$dn]['macAddress'];
}
/* We are a workstation. Add current mac.
*/
$mac = $this->parent->by_object['workgeneric']->netConfigDNS->macAddress;
- if(!empty($mac) && !preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/",$this->orig_dn)){
+ if(!empty($mac) && !preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/",$this->orig_dn)){
$macs[] = $mac;
}
}
diff --git a/gosa-plugins/goto/admin/systems/goto/class_workstationGeneric.inc b/gosa-plugins/goto/admin/systems/goto/class_workstationGeneric.inc
index b5ff4338ccee2d54b42253e8b04a8157c10400a4..777198691f2e739b60c28e480faec6c4a548881b 100644 (file)
if ($this->dn == "new"){
$ui= get_userinfo();
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
- } elseif(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", $this->dn)){
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", "", $this->dn);
+ } elseif(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $this->dn)){
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", "", $this->dn);
}else{
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("workstationRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("workgeneric", "workstationRDN"), '/')."/i", "", $this->dn);
}
/* Create an array of all Syslog servers */
$message= array_merge($message, $this->netConfigDNS->check());
}
- $this->dn= "cn=".$this->cn.",".get_ou('workstationRDN').$this->base;
+ $this->dn= "cn=".$this->cn.",".get_ou("workgeneric", "workstationRDN").$this->base;
if ($this->cn == ""){
$message[]= msgPool::required(_("Name"));
}
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
- if (preg_match("/cn=dhcp,/",$attrs['dn']) || preg_match ("/,".preg_quote(get_ou('systemIncomingRDN'), '/')."/i", $ldap->getDN())){
+ if (preg_match("/cn=dhcp,/",$attrs['dn']) || preg_match ("/,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $ldap->getDN())){
continue;
} else {
if ($attrs['dn'] != $this->orig_dn){
}else{
/* Warn the user, that this host is currently installing */
if($this->currently_installing && !$this->currently_installing_warned &&
- !preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/i",$this->orig_dn)){
+ !preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i",$this->orig_dn)){
/* Force aborting without message dialog */
$message[] = "";
diff --git a/gosa-plugins/goto/admin/systems/goto/class_workstationService.inc b/gosa-plugins/goto/admin/systems/goto/class_workstationService.inc
index 4b131ec53ee2d3e83809d10751cecb9a8337ada9..5cf847b1bb0b107e16b3398906eae458cb8bac4d 100644 (file)
/* Load phone hardware list
*/
- $tmp = get_sub_list("(objectClass=goFonHardware)","",array(get_ou("phoneRDN")),
+ $tmp = get_sub_list("(objectClass=goFonHardware)","",array(get_ou("phoneGeneric", "phoneRDN")),
$this->config->current['BASE'],array("cn","description"), GL_NO_ACL_CHECK);
foreach($tmp as $attrs){
$cn= $attrs['cn'][0];
*/
$deps_a = array(
get_people_ou(),
- get_ou("ogroupRDN"),
- get_ou("serverRDN"),
- get_ou("terminalRDN"),
- get_ou("workstationRDN"),
- get_ou("printerRDN"),
- get_ou("componentRDN"),
- get_ou("phoneRDN"));
+ get_ou("group", "ogroupRDN"),
+ get_ou("servgeneric", "serverRDN"),
+ get_ou("termgeneric", "terminalRDN"),
+ get_ou("workgeneric", "workstationRDN"),
+ get_ou("printgeneric", "printerRDN"),
+ get_ou("componentGeneric", "componentRDN"),
+ get_ou("phoneGeneric", "phoneRDN"));
$tmp = get_sub_list("(goFonHardware=*)","",$deps_a,$this->config->current['BASE'],
array('cn','dn','goFonHardware'),GL_NO_ACL_CHECK);
*/
$p = $this->parent->by_object['ogroup'];
foreach($p->memberList as $dn => $obj){
- if(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/",$dn)) continue;
+ if(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/",$dn)) continue;
if(isset($p->objcache[$dn]['macAddress']) && !empty($p->objcache[$dn]['macAddress'])){
$macs[] = $p->objcache[$dn]['macAddress'];
}
/* We are a workstation. Add current mac.
*/
$mac = $this->parent->by_object['workgeneric']->netConfigDNS->macAddress;
- if(!empty($mac) && !preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/",$this->orig_dn)){
+ if(!empty($mac) && !preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/",$this->orig_dn)){
$macs[] = $mac;
}
}
diff --git a/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc b/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc
index d28a4b20149209c3da65e5e72d8f4dd056c12062..53ae8325af8f4b59f74b944c1773cc3380f23e95 100644 (file)
$ldap= $this->config->get_ldap_link();
/* Strip relevant part from dn, keep trailing ',' */
- $tmp= preg_replace("/^cn=[^,]+,".preg_quote(get_ou('terminalRDN'), '/')."/i", "", $this->dn);
+ $tmp= preg_replace("/^cn=[^,]+,".preg_quote(get_ou("termgeneric", "terminalRDN"), '/')."/i", "", $this->dn);
$tmp= preg_replace("/".$this->config->current['BASE']."$/i", "", $tmp);
/* Walk from top to base and try to load default values for
while (TRUE){
$tmp= preg_replace ("/^[^,]+,/", "", $tmp);
- $ldap->cat("cn=default,".get_ou('terminalRDN').$tmp.
+ $ldap->cat("cn=default,".get_ou("termgeneric", "terminalRDN").$tmp.
$this->config->current['BASE'], array('gotoTerminalPath'));
$attrs= $ldap->fetch();
if (isset($attrs['gotoTerminalPath'])){
diff --git a/gosa-plugins/goto/admin/systems/goto/tabs_printers.inc b/gosa-plugins/goto/admin/systems/goto/tabs_printers.inc
index 6a7e0e02d4323b767aa355e05fa1793f68e543c2..95ae791d954ae5657e09c7c5a31602600fff4df9 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
$baseobject= $this->by_object['printgeneric'];
- $this->dn= "cn=$baseobject->cn,".get_ou('printerRDN').$baseobject->base;
+ $this->dn= "cn=$baseobject->cn,".get_ou("printgeneric", "printerRDN").$baseobject->base;
$baseobject->dn= $this->dn;
foreach ($this->by_object as $key => $obj){
diff --git a/gosa-plugins/goto/admin/systems/goto/tabs_terminal.inc b/gosa-plugins/goto/admin/systems/goto/tabs_terminal.inc
index b1adb932836e4177e9f932b1fe2ff037c623630b..444182e7e19a4733451e04c0e7dc5c1e143d2b99 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
$baseobject= $this->by_object['termgeneric'];
- $this->dn= "cn=".$baseobject->cn.",".get_ou('terminalRDN').$baseobject->base;
+ $this->dn= "cn=".$baseobject->cn.",".get_ou("termgeneric", "terminalRDN").$baseobject->base;
$baseobject->dn= $this->dn;
if($this->dn != $baseobject->orig_dn && $baseobject->orig_dn != "new"){
diff --git a/gosa-plugins/goto/admin/systems/goto/tabs_workstation.inc b/gosa-plugins/goto/admin/systems/goto/tabs_workstation.inc
index 32bcaea5c2ba75c7d882c25452dfbd628153d5b7..83fbaf7ac5d9fec1170efd604d28af2fd0b44efd 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
$baseobject= $this->by_object['workgeneric'];
- $this->dn= "cn=".$baseobject->cn.",".get_ou('workstationRDN').$baseobject->base;
+ $this->dn= "cn=".$baseobject->cn.",".get_ou("workgeneric", "workstationRDN").$baseobject->base;
if($this->dn != $baseobject->orig_dn && $baseobject->orig_dn != "new"){
diff --git a/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc b/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc
index d62ad841ae82603c826cf1cc8033fe3fb1ed1737..c3bde1a0ccd8924027872c17f62038bac47b7dea 100644 (file)
function process_mounts() {
- $clip = "cn=" . $this->cn . ",".get_ou('serverRDN');
+ $clip = "cn=" . $this->cn . ",".get_ou("servgeneric", "serverRDN");
$mountsdn = "cn=mounts," . substr($this->dn, strlen($clip));
$mounts = array(
diff --git a/gosa-plugins/goto/admin/systems/services/shares/class_servNfs.inc b/gosa-plugins/goto/admin/systems/services/shares/class_servNfs.inc
index 8e50b5fc20228347344fdd49e6b972ba990cb847..b0b6b1156b1a8974cfd5eb9abe7199b04b7ea00a 100644 (file)
$smarty->assign("mount_checked", "checked");
} else {
$tmp = explode(",", $this->dn);
- $clip = $tmp[0] . ",".get_ou('serverRDN');
+ $clip = $tmp[0] . ",".get_ou("servgeneric", "serverRDN");
$mountsdn = "cn=mounts," . substr($this->dn, strlen($clip));
switch ($this->type) {
case "netatalk" : {
diff --git a/gosa-plugins/goto/personal/environment/hotplugSelect/class_hotplugSelect.inc b/gosa-plugins/goto/personal/environment/hotplugSelect/class_hotplugSelect.inc
index fa512efdabc949eb3642ea7a0f2aa3915bcbd978..5ee3d492e1ca8ff43603a37db9b17f99911f2011 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("deviceRDN"));
+ $this->storagePoints = array(get_ou("deviceGeneric", "deviceRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/goto/personal/environment/printerSelect/class_printerSelect.inc b/gosa-plugins/goto/personal/environment/printerSelect/class_printerSelect.inc
index bf42dec6c66bdf60618e39d8d8a48e5db8ae825c..78af46c89adfd04b6c925b3a16307761b1029bcd 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("printerRDN"));
+ $this->storagePoints = array(get_ou("printgeneric", "printerRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/ldapmanager/addons/ldapmanager/class_exportxls.inc b/gosa-plugins/ldapmanager/addons/ldapmanager/class_exportxls.inc
index 90e835c925cddc6755459592b509f1f61076243c..14b734ac9d795915053af6bf49fa87052535a57a 100644 (file)
$smarty->assign("deplist", $bases);
$smarty->assign("choicelist",array( get_people_ou() =>"users" ,
get_groups_ou() =>"groups" ,
- get_ou('systemRDN') =>"computers",
- get_ou('serverRDN') =>"servers",
+ get_ou("systemManagement", "systemRDN") =>"computers",
+ get_ou("servgeneric", "serverRDN") =>"servers",
"dc=addressbook," =>"addressbook"));
// Get the LDAP link, to generate the Export
index b4f19fbc41d6fee0a5ac7b50b6ec7d66556f2e7b..649d5200d0098e54f6b5e32c1f3763d25c8841ba 100644 (file)
/* SYSTEMS
Get all systems from th $dn
and put them into the xls work sheet */
- case get_ou('systemRDN'):
+ case get_ou("systemManagement", "systemRDN"):
$name_section=_("Servers");
$computers= $ldap->gen_xls($dn,"(&(objectClass=*)(cn=*))",array("cn","description","uid"));
/* SYSTEMS
Get all systems from th $dn
and put them into the xls work sheet */
- case get_ou('serverRDN'): $servers= $ldap->gen_xls($dn,"(objectClass=*)",array("cn"));
+ case get_ou("servgeneric", "serverRDN"): $servers= $ldap->gen_xls($dn,"(objectClass=*)",array("cn"));
$intitul=array(_("Server name").":");
//name of the xls file
$computers= $ldap->gen_xls("ou=computers,".$dn,"(objectClass=*)",array("cn","description","uid"));
$computers_intitul=array(_("Description").":",_("UID").":");
//data about servers
- $servers= $ldap->gen_xls(get_ou('serverRDN').$dn,"(objectClass=*)",array("cn"));
+ $servers= $ldap->gen_xls(get_ou("servgeneric", "serverRDN").$dn,"(objectClass=*)",array("cn"));
$servers_intitul=array(_("Name").":");
//data about addressbook
$address= $ldap->gen_xls("dc=addressbook,".$dn,"(objectClass=*)",
diff --git a/gosa-plugins/mail/personal/mail/mailAddressSelect/class_mailAddressSelect.inc b/gosa-plugins/mail/personal/mail/mailAddressSelect/class_mailAddressSelect.inc
index 89820d9e22fa08473f499bbc11272bcb4365f585..849276a49755336378354a6692119d7c16cc0a06 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("userRDN"), get_ou('groupRDN'));
+ $this->storagePoints = array(get_ou("core", "userRDN"), get_ou("core", "groupRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/opsi/admin/opsi/class_opsi.inc b/gosa-plugins/opsi/admin/opsi/class_opsi.inc
index b79e29d80d7c94316861e08958d3fba8ac663246..0dd5b04baad50b0e63d03de8fce793bcaf18b8cd 100644 (file)
foreach($res as $entry){
if(!isset($entry['MAC'][0]['VALUE'])) $entry['MAC'][0]['VALUE'] = "";
$obj = array(
- "dn" => "opsi:=".$entry['NAME'][0]['VALUE'].",".get_ou("sambaMachineAccountRDN").$this->config->current['BASE'],
+ "dn" => "opsi:=".$entry['NAME'][0]['VALUE'].",".get_ou("wingeneric", "sambaMachineAccountRDN").$this->config->current['BASE'],
"objectClass" => array("gosa_opsi_client"),
"cn" => array(0 => $entry['NAME'][0]['VALUE']),
"macAddress" => array(0 => $entry['MAC'][0]['VALUE']),
diff --git a/gosa-plugins/rolemanagement/admin/roleManagement/class_roleGeneric.inc b/gosa-plugins/rolemanagement/admin/roleManagement/class_roleGeneric.inc
index d2f9487b768b9e38c9050de67da7d3db9968b375..0270f6ae913476ef0ded15aab02a55bbf43fc620 100644 (file)
$ui = get_userinfo();
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
} else {
- $this->base= preg_replace("/^[^,]+,".preg_quote(get_ou("roleRDN"), '/i')."/","",$this->dn);
+ $this->base= preg_replace("/^[^,]+,".preg_quote(get_ou("roleGeneric", "roleRDN"), '/i')."/","",$this->dn);
}
// Keep track of naming attribute modifications
diff --git a/gosa-plugins/rolemanagement/admin/roleManagement/class_roleManagement.inc b/gosa-plugins/rolemanagement/admin/roleManagement/class_roleManagement.inc
index 38d45e7aa413cfa502846df4d2e7d82fa1c32f80..968baf6f9505a16109c45b82d6a5322657df0c99 100644 (file)
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("roleRDN"));
+ $this->storagePoints = array(get_ou("roleGeneric", "roleRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/rolemanagement/admin/roleManagement/tabs_roles.inc b/gosa-plugins/rolemanagement/admin/roleManagement/tabs_roles.inc
index 5ab586cf633f2cfdf55a4a7ba3dabb35a428e3ef..98b3c00c38a6fa798b788d1df42a8cc75812d4dd 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
- $new_dn= 'cn='.$baseobject->cn.','.get_ou("roleRDN").$baseobject->base;
+ $new_dn= 'cn='.$baseobject->cn.','.get_ou("roleGeneric", "roleRDN").$baseobject->base;
/* Move role? */
if ($this->dn != $new_dn){
diff --git a/gosa-plugins/samba/admin/systems/samba/class_winGeneric.inc b/gosa-plugins/samba/admin/systems/samba/class_winGeneric.inc
index 1ba789d10e3eb8693e0483aeee75290ba8fe302c..dd09288bbfa4b34d448ceceaed1f32685466d4b4 100644 (file)
$ui = get_userinfo();
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
$this->cn= "";
- } elseif(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", $this->dn)){
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", "", $this->dn);
+ } elseif(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $this->dn)){
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", "", $this->dn);
} else {
$this->base= preg_replace ("/^[^,]+,".preg_quote(get_winstations_ou(), '/')."/i", "", $this->dn);
}
/* Call common method to give check the hook */
$message= plugin::check();
$message= array_merge($message, $this->netConfigDNS->check());
- $this->dn= "cn=".$this->uid.",".get_ou('sambaMachineAccountRDN').$this->base;
+ $this->dn= "cn=".$this->uid.",".get_ou("wingeneric", "sambaMachineAccountRDN").$this->base;
if(!$this->acl_is_createable()){
$message[]= msgPool::permCreate();
diff --git a/gosa-plugins/systems/admin/systems/class_componentGeneric.inc b/gosa-plugins/systems/admin/systems/class_componentGeneric.inc
index 209b14fca746c7e8de51080e52e72219c4f1c72e..869d7fe04b444b0cf68f49833dff5f508da34246 100644 (file)
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
$this->cn= "";
} else {
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("componentRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("componentGeneric", "componentRDN"), '/')."/i", "", $this->dn);
}
$this->netConfigDNS = new termDNS($this->config,$this,$this->objectclasses, true);
/* Save dn for later references */
$message= plugin::check();
$message= array_merge($message,$this->netConfigDNS->check());
- $this->dn= "cn=".$this->cn.",".get_ou('componentRDN').$this->base;
+ $this->dn= "cn=".$this->cn.",".get_ou("componentGeneric", "componentRDN").$this->base;
if ($this->cn == "" ){
$message[]= msgPool::required(_("Component name"));
if(preg_match("/cn=dhcp,/",$attrs['dn'])){
continue;
}
- if ($attrs['dn'] != $this->orig_dn && preg_match("/".preg_quote(get_ou("componentRDN"), '/')."/i",$attrs['dn'])){
+ if ($attrs['dn'] != $this->orig_dn && preg_match("/".preg_quote(get_ou("componentGeneric", "componentRDN"), '/')."/i",$attrs['dn'])){
$message[]= msgPool::duplicated(_("Component name"));
break;
}
diff --git a/gosa-plugins/systems/admin/systems/class_filterSYSTEMS.inc b/gosa-plugins/systems/admin/systems/class_filterSYSTEMS.inc
index d794cc807424ed315f00d06e2ea689428d6b2850..4c67c8bcda4c4d9cafe3dfa261fb8f2f46e8f033 100644 (file)
foreach($entries as $key => $entry){
- if(preg_match("/".preg_quote(get_ou('systemIncomingRDN'),'/')."/i", $entry['dn'])){
+ if(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"),'/')."/i", $entry['dn'])){
// Detect incoming types
if(in_array('gotoWorkstation', $entry['objectClass'])){
diff --git a/gosa-plugins/systems/admin/systems/class_servGeneric.inc b/gosa-plugins/systems/admin/systems/class_servGeneric.inc
index d8891da71c6f4c9143e83e24466de7270bfc34fe..10ef0acf69225c2eb0a936c2f0141184a60d3f6e 100644 (file)
$ui= get_userinfo();
$this->base= dn2base(session::global_is_set("CurrentMainBase")?"cn=dummy,".session::global_get("CurrentMainBase"):$ui->dn);
$this->cn= "";
- } elseif(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", $this->dn)){
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("systemIncomingRDN"), '/')."/i", "", $this->dn);
+ } elseif(preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", $this->dn)){
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i", "", $this->dn);
} else {
- $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("serverRDN"), '/')."/i", "", $this->dn);
+ $this->base= preg_replace ("/^[^,]+,".preg_quote(get_ou("servgeneric", "serverRDN"), '/')."/i", "", $this->dn);
}
$this->netConfigDNS = new termDNS($this->config,$this,$this->objectclasses);
$this->netConfigDNS->set_acl_category("server");
/* Call common method to give check the hook */
$message= plugin::check();
$message= array_merge($message, $this->netConfigDNS->check());
- $this->dn= "cn=".$this->cn.",".get_ou('serverRDN').$this->base;
+ $this->dn= "cn=".$this->cn.",".get_ou("servgeneric", "serverRDN").$this->base;
/* must: cn */
if ($this->cn == ""){
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
if ($attrs['dn'] != $this->orig_dn){
- if(!preg_match("/cn=dhcp,/",$attrs['dn']) && !preg_match("/,".preg_quote(get_ou('systemIncomingRDN'), '/')."/i",$attrs['dn']) && preg_match("/,".preg_quote(get_ou('serverRDN'), '/')."/i",$attrs['dn'])){
+ if(!preg_match("/cn=dhcp,/",$attrs['dn']) && !preg_match("/,".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i",$attrs['dn']) && preg_match("/,".preg_quote(get_ou("servgeneric", "serverRDN"), '/')."/i",$attrs['dn'])){
$message[]= msgPool::duplicated(_("Server name"));
break;
}
}
/* Warn the user, that this host is currently installing */
- if($this->currently_installing && !$this->currently_installing_warned && !preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/i",$this->orig_dn)){
+ if($this->currently_installing && !$this->currently_installing_warned && !preg_match("/".preg_quote(get_ou("ArpNewDevice", "systemIncomingRDN"), '/')."/i",$this->orig_dn)){
/* Force aborting without message dialog */
$message[] = "";
diff --git a/gosa-plugins/systems/admin/systems/class_systemManagement.inc b/gosa-plugins/systems/admin/systems/class_systemManagement.inc
index d6934e9e2507e86073ba72418f22c5d5560d00f7..066a767dd19b23cdefd954e54e2b4f335cf8f6df 100644 (file)
*/
static function incomingFilterConverter($filter)
{
- $rdn = preg_replace("/^[^=]*=/", "", get_ou('systemIncomingRDN'));
+ $rdn = preg_replace("/^[^=]*=/", "", get_ou("ArpNewDevice", "systemIncomingRDN"));
$rdn = preg_replace("/,.*$/","",$rdn);
return(preg_replace("/%systemIncomingRDN/", $rdn,$filter));
}
$data['OG'], "<b>Selected ogroup:</b>");
if($data['OG'] != "none"){
- $this->tabObject->base = preg_replace("/^[^,]+,".preg_quote(get_ou('ogroupRDN'), '/')."/i", "", $data['OG']);
+ $this->tabObject->base = preg_replace("/^[^,]+,".preg_quote(get_ou("group", "ogroupRDN"), '/')."/i", "", $data['OG']);
$this->tabObject->by_object[$plugClass]->baseSelector->setBase($this->tabObject->base);
} else {
$this->tabObject->by_object[$plugClass]->baseSelector->setBase($headpage->getBase());
"aclCategory" => "opsi"),
"goServer" => array(
- "ou" => get_ou('serverRDN'),
+ "ou" => get_ou("servgeneric", "serverRDN"),
"plugClass" => "servgeneric",
"tabClass" => "servtabs",
"tabDesc" => "SERVTABS",
"aclCategory" => "server"),
"gotoWorkstation" => array(
- "ou" => get_ou('workstationRDN'),
+ "ou" => get_ou("workgeneric", "workstationRDN"),
"plugClass" => "workgeneric",
"tabClass" => "worktabs",
"tabDesc" => "WORKTABS",
"aclCategory" => "workstation"),
"gotoTerminal" => array(
- "ou" => get_ou('terminalRDN'),
+ "ou" => get_ou("termgeneric", "terminalRDN"),
"plugClass" => "termgeneric",
"tabClass" => "termtabs",
"sendEvents" => TRUE,
"aclCategory" => "terminal"),
"gotoPrinter" => array(
- "ou" => get_ou('printerRDN'),
+ "ou" => get_ou("printgeneric", "printerRDN"),
"plugClass" => "printgeneric",
"tabClass" => "printtabs",
"tabDesc" => "PRINTTABS",
"aclCategory" => "printer"),
"FAKE_OC_NewDevice" => array(
- "ou" => get_ou('systemIncomingRDN'),
+ "ou" => get_ou("ArpNewDevice", "systemIncomingRDN"),
"plugClass" => "termgeneric",
"tabClass" => "termtabs",
"sendEvents" => TRUE,
"aclCategory" => "terminal"),
"goFonHardware" => array(
- "ou" => get_ou('phoneRDN'),
+ "ou" => get_ou("phoneGeneric", "phoneRDN"),
"plugClass" => "phoneGeneric",
"tabClass" => "phonetabs",
"tabDesc" => "PHONETABS",
"aclCategory" => "winworkstation"),
"ieee802Device" => array(
- "ou" => get_ou('componentRDN'),
+ "ou" => get_ou("componentGeneric", "componentRDN"),
"plugClass" => "componentGeneric",
"sendEvents" => FALSE,
"tabClass" => "componenttabs",
diff --git a/gosa-plugins/systems/admin/systems/class_termDNS.inc b/gosa-plugins/systems/admin/systems/class_termDNS.inc
index dc37a189764298d1204f79dda65bfe547c31b61e..ccfe124651fb1a60f2387f1d14ad920fb0ebd934 100644 (file)
over the whole ldap server was 10 to 20 times slower.
*/
$deps = array();
- $ou = preg_replace("/,.*$/","",get_ou("systemRDN"));
- $a_ous = array(get_ou("serverRDN"),
- get_ou("terminalRDN"),
- get_ou("workstationRDN"),
- get_ou("printerRDN"),
- get_ou("phoneRDN"),
- get_ou("componentRDN"));
+ $ou = preg_replace("/,.*$/","",get_ou("systemManagement", "systemRDN"));
+ $a_ous = array(get_ou("servgeneric", "serverRDN"),
+ get_ou("termgeneric", "terminalRDN"),
+ get_ou("workgeneric", "workstationRDN"),
+ get_ou("printgeneric", "printerRDN"),
+ get_ou("phoneGeneric", "phoneRDN"),
+ get_ou("componentGeneric", "componentRDN"));
$ldap = $this->config->get_ldap_link();
$ldap->cd($this->config->current['BASE']);
diff --git a/gosa-plugins/systems/admin/systems/systemSelect/class_systemSelect.inc b/gosa-plugins/systems/admin/systems/systemSelect/class_systemSelect.inc
index c46ce62863705d28a5d6484e6b0035d02fbd1d8f..875a555123057a1f0849e39bd3dabbb6fb89eca2 100644 (file)
{
$this->config = $config;
$this->ui = $ui;
- $this->storagePoints = array(get_ou("serverRDN"), get_ou("workstationRDN"), get_ou('terminalRDN'));
+ $this->storagePoints = array(get_ou("servgeneric", "serverRDN"), get_ou("workgeneric", "workstationRDN"), get_ou("termgeneric", "terminalRDN"));
// Build filter
if (session::global_is_set(get_class($this)."_filter")){
diff --git a/gosa-plugins/systems/admin/systems/tabs_component.inc b/gosa-plugins/systems/admin/systems/tabs_component.inc
index 5dfc787ccf7b029404c4fe6163534fee7559b9b5..ac1a6ab5eab91af846dc39988f374a8848dede8e 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
$baseobject= $this->by_object['componentGeneric'];
- $this->dn= "cn=$baseobject->cn,".get_ou('componentRDN').$baseobject->base;
+ $this->dn= "cn=$baseobject->cn,".get_ou("componentGeneric", "componentRDN").$baseobject->base;
if($this->dn != $baseobject->orig_dn && $baseobject->orig_dn != "new"){
diff --git a/gosa-plugins/systems/admin/systems/tabs_server.inc b/gosa-plugins/systems/admin/systems/tabs_server.inc
index ea977581a05597e6bf26fc7f8819b7873ffab1d4..1acab8a03081398374fa1912b1c7759bd599a0c2 100644 (file)
/* Check for new 'dn', in order to propagate the
'dn' to all plugins */
$baseobject= $this->by_object['servgeneric'];
- $this->dn= "cn=$baseobject->cn,".get_ou('serverRDN').$baseobject->base;
+ $this->dn= "cn=$baseobject->cn,".get_ou("servgeneric", "serverRDN").$baseobject->base;
/* cn is not case sensitive for ldap, but for php it is!! */
if($baseobject->orig_dn != "new"){