From 8c5fcc2f098922232118391636b3ac8dd13a4d7d Mon Sep 17 00:00:00 2001 From: cajus Date: Thu, 1 Oct 2009 11:59:35 +0000 Subject: [PATCH] Perlimitary domain support - not working yet git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14435 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../departments/class_departmentGeneric.inc | 2 +- .../departments/class_departmentManagement.inc | 18 +++++++++++++++--- .../departments/class_divListDepartment.inc | 4 ++-- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/gosa-core/plugins/admin/departments/class_departmentGeneric.inc b/gosa-core/plugins/admin/departments/class_departmentGeneric.inc index c5f5e0143..5a4c69cbe 100644 --- a/gosa-core/plugins/admin/departments/class_departmentGeneric.inc +++ b/gosa-core/plugins/admin/departments/class_departmentGeneric.inc @@ -209,7 +209,7 @@ class department extends plugin $dep_types = departmentManagement::get_support_departments(); $tpl =""; foreach($dep_types as $key => $data){ - if($data['ATTR'] == $this->type){ + if($data['OC'] == $this->type){ $tpl = $data['TPL']; break; } diff --git a/gosa-core/plugins/admin/departments/class_departmentManagement.inc b/gosa-core/plugins/admin/departments/class_departmentManagement.inc index bb0a20de8..50ba9f3ff 100644 --- a/gosa-core/plugins/admin/departments/class_departmentManagement.inc +++ b/gosa-core/plugins/admin/departments/class_departmentManagement.inc @@ -116,7 +116,7 @@ class departmentManagement extends plugin $types = $this->get_support_departments(); $type = ""; foreach($types as $key => $data){ - if($data['ATTR'] == $s_entry){ + if($data['OC'] == $s_entry){ $type = $key; break; } @@ -125,7 +125,7 @@ class departmentManagement extends plugin if(isset($types[$type])){ $tab = $types[$type]['TAB']; $acl = $types[$type]['ACL']; - $this->deptabs= new deptabs($this->config,$this->config->data['TABS'][$tab], $this->dn,"department"); + $this->deptabs= new deptabs($this->config, $this->config->data['TABS'][$tab], $this->dn, "department"); $this->deptabs->set_acl_base($this->DivListDepartment->selectedBase); }else{ trigger_error("Invalid / Not implemented countainer type."); @@ -152,7 +152,7 @@ class departmentManagement extends plugin $data = array(); foreach($types as $oc => $type){ if(in_array($oc,$entry['objectClass'])){ - $data = $type; + $data = $oc; break; } } @@ -556,6 +556,18 @@ class departmentManagement extends plugin $types['dcObject']['TITLE'] = _("Domain Component"); $types['dcObject']['TPL'] = "dcObject.tpl"; + /* Domain + */ + $types['domain']['ACL'] = "domain"; + $types['domain']['CLASS'] = "domain"; + $types['domain']['ATTR'] = "dc"; + $types['domain']['TAB'] = "DOMAIN_TABS"; + $types['domain']['OC'] = "domain"; + $types['domain']['IMG'] = "plugins/departments/images/domain.png"; + $types['domain']['IMG_FULL']= "plugins/departments/images/domain.png"; + $types['domain']['TITLE'] = _("Domain"); + $types['domain']['TPL'] = "domain.tpl"; + /* Country object */ $types['country']['ACL'] = "country"; diff --git a/gosa-core/plugins/admin/departments/class_divListDepartment.inc b/gosa-core/plugins/admin/departments/class_divListDepartment.inc index bcbaae300..32a5a4ab5 100644 --- a/gosa-core/plugins/admin/departments/class_divListDepartment.inc +++ b/gosa-core/plugins/admin/departments/class_divListDepartment.inc @@ -98,8 +98,8 @@ class divListDepartment extends MultiSelectWindow $types = $this->parent->get_support_departments(); foreach($types as $type){ if(preg_match("/c/",$ui->get_permissions($this->selectedBase ,"department/".$type['ACL']))){ - $s.= "...|". - " ".$type['TITLE']." (".$type['ATTR'].")|dep_new_".$type['ATTR']."|\n"; + $s.= "...|". + " ".$type['TITLE']." (".$type['OC'].")|dep_new_".$type['OC']."|\n"; } } -- 2.30.2