Code

Fixed problem creating phones with new dns handling
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 21 Mar 2006 10:33:41 +0000 (10:33 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 21 Mar 2006 10:33:41 +0000 (10:33 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2877 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/systems/class_phoneGeneric.inc
plugins/admin/systems/class_termDNS.inc

index 863e7c3d94a0dea690123d1bef6ff8b2a8c4dd7e..62322f574abf0ed70d3e05f3967fbcec5caf37e2 100644 (file)
@@ -364,6 +364,8 @@ class phoneGeneric extends plugin
       $this->attrs['goFonDefaultIP'] = $this->netConfigDNS->ipHostNumber;
     }    
 
+    $this->attrs = $this->netConfigDNS->getVarsForSaving($this->attrs);
+
     /* Write back to ldap */
     $ldap= $this->config->get_ldap_link();
     if ($this->orig_dn == 'new'){
index d7d43acf769ce3f150001bb686689234a61f87f4..c7e70311d97c938427cfd1e84cbef7f52b66ca2a 100644 (file)
@@ -153,6 +153,16 @@ class termDNS extends plugin
     $this->DNSinitially_was_account = $this->DNS_is_account;
   }
 
+  function getVarsForSaving($attrs) 
+  {
+    foreach($this->attributes as $attr){
+      if(!empty($this->$attr)){
+        $attrs[$attr] = $this->$attr;
+      }
+    }
+    return($attrs); 
+  }
+
   function execute()
   {
          /* Call parent execute */