diff --git a/plugins/gofon/phoneaccount/class_phoneAccount.inc b/plugins/gofon/phoneaccount/class_phoneAccount.inc
index 80660f27e9d03b329bd41f6924a296a779f32886..b38336fe90e1a65f25d0ed81968c0a774355b28e 100644 (file)
$ldap= $this->config->get_ldap_link();
$ldap->cd($this->dn);
$this->cleanup();
-$ldap->modify ($this->attrs);
+ $ldap->modify ($this->attrs);
- show_ldap_error($ldap->get_error());
+ show_ldap_error($ldap->get_error(), _("Saving phone account failed"));
/* Optionally execute a command after we're done */
function remove_from_parent()
{
+ if(!$this->initially_was_account) return;
+
foreach($this->attributes as $key=>$val){
if(in_array($val,array("uid","cn"))){
unset($this->attributes[$key]);
}
$ldap->cd($this->dn);
$this->cleanup();
-$ldap->modify ($this->attrs);
+ $ldap->modify ($this->attrs);
- show_ldap_error($ldap->get_error());
+ show_ldap_error($ldap->get_error(), _("Removing phone account failed"));
/* Optionally execute a command after we're done */
@mysql_close($r_con);
}
}
+
+ /* Create phoneAccount part of copy & paste dialog */
function getCopyDialog()
{
if(!$this->is_account) return("");
return($ret);
}
+ /* Save posts from copy & paste dialog dialog */
function saveCopyDialog()
{
if(!$this->is_account) return;