Code

Moved conferences from base to ,ou=conferences,ou=asterisk,ou=configs,ou=systems,
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 22 May 2006 04:18:17 +0000 (04:18 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 22 May 2006 04:18:17 +0000 (04:18 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3472 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/gofon/conference/class_phoneConferenceGeneric.inc
plugins/gofon/conference/class_phoneConferenceManagment.inc
plugins/gofon/conference/tabs_conference.inc

index 7b5fed530ba63620e7b61fb0ebf3ff3b38fdeb0b..ab70ac5fbb31b9761ceccdf276a48474b823d29a 100644 (file)
@@ -466,16 +466,17 @@ class conference extends plugin
     }
 
     $ldap= $this->config->get_ldap_link();
-
+    $ldap->cd($this->config->current['BASE']);
     $ldap->cat($this->dn, array('dn'));
-    $a= $ldap->fetch();
-    $ldap->cd($this->dn);
-    if (count($a)){
+
+    if ($ldap->count()){
+      $ldap->cd($this->dn);
       $this->cleanup();
       $ldap->modify ($this->attrs); 
-
       $this->handle_post_events('modify');
     } else {
+      $ldap->create_missing_trees(preg_replace('/^[^,]+,/', '', $this->dn));
+      $ldap->cd($this->dn);
       $ldap->add($this->attrs);
       $this->handle_post_events('add');
     }
index a6a20c7d2a3e8728c026fa0ddaef0df07785a763..5bf53a119714f539f099a556426b76511e51a3ec 100644 (file)
@@ -269,7 +269,7 @@ class phoneConferenceManagment extends plugin
    */
   function reload()
   {
-    $Base             = $this->DivListConference->selectedBase;
+    $Base             = "ou=conferences,ou=asterisk,ou=configs,ou=systems,".$this->DivListConference->selectedBase;
     $SubSearch        = $this->DivListConference->SubSearch;
     $Regex            = $this->DivListConference->Regex;
     $Flags            = GL_SIZELIMIT ; 
index e6e800aed2490fde55f83a2aa038f52b556d1dc8..05271c0846759bdb6ab0f7f44649d8ccf9f1075f 100644 (file)
@@ -19,7 +19,7 @@ class conferencetabs extends tabs
   function save()
   {
        $baseobject= $this->by_object['conference'];
-       $new_dn= 'cn='.$baseobject->cn.','.$baseobject->base;
+       $new_dn= 'cn='.$baseobject->cn.',ou=conferences,ou=asterisk,ou=configs,ou=systems,'.$baseobject->base;
 
        if(strtolower($this->dn)==strtolower($new_dn)){
                $this->dn=$new_dn;