Code

Include personal title in cn/dn
[gosa.git] / plugins / personal / connectivity / class_oxchangeAccount.inc
index 6104d2574cda31fa7190842f65b4d056536d2da7..58c998f1e2c97cb081c69ce5225aaef0a21b1a4a 100644 (file)
@@ -39,6 +39,8 @@ class oxchangeAccount extends plugin
   var $attributes= array("OXAppointmentDays", "OXTaskDays", "OXTimeZone","mailEnabled");
   var $objectclasses= array("OXUserObject");
 
+  var $uid = "";
+
   var $oxconf = array();
   var $timezones=array(
       "Africa/Abidjan",
@@ -582,9 +584,9 @@ class oxchangeAccount extends plugin
 
   var $dnmode= "";
 
-  function oxchangeAccount ($config, $dn= NULL)
+  function oxchangeAccount ($config, $dn= NULL, $parent= NULL)
   {
-    plugin::plugin ($config, $dn);
+    plugin::plugin ($config, $dn, $parent);
     for ($i=0;$i<count($this->config->data['TABS']['CONNECTIVITY']);$i++){
       if($this->config->data['TABS']['CONNECTIVITY'][$i]['CLASS']=='oxchangeAccount') {
         $this->oxconf=$this->config->data['TABS']['CONNECTIVITY'][$i];
@@ -592,6 +594,11 @@ class oxchangeAccount extends plugin
       }
     }
 
+    /* Setting uid to default */
+    if(isset($this->attrs['uid'][0])){
+      $this->uid = $this->attrs['uid'][0];
+    }
+
     $this->dnmode= $this->config->current['DNMODE'];
   }
 
@@ -800,8 +807,7 @@ class oxchangeAccount extends plugin
     preg_match("/^(\w+(?=\=))=((\w|\s|\.)+(?=\,)),.*/",$this->dn,$uidarray);
     $uid=$uidarray[2];
     if (trim($uid) == "") {
-      print_red(_("The Open-Xchange accountname is empty and thus invalid! Check to make sure that ".
-                  "you are not using any strange characters in the loginname."));
+      print_red(_("The Open-Xchange accountname is empty and thus invalid! Check to make sure that you are not using any strange characters in the loginname."));
       return;
     }