From 793fbb375529a5b60d733fd587d51ab96da989a5 Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 16 Oct 2007 10:57:32 +0000 Subject: [PATCH] Fixed dhcp saving for renamed objects git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5@7573 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/systems/class_termDNS.inc | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/admin/systems/class_termDNS.inc b/plugins/admin/systems/class_termDNS.inc index b92661132..97abc0633 100644 --- a/plugins/admin/systems/class_termDNS.inc +++ b/plugins/admin/systems/class_termDNS.inc @@ -559,10 +559,15 @@ class termDNS extends plugin /* DHCP Added */ if(!$this->initial_dhcp_is_Account && $this->dhcp_is_Account){ + + $dn = "cn=".$this->cn.",".$this->dhcpParentNode; + $attrs = $this->dhcpHostEntry; + $attrs['cn'] = $this->cn; + unset($attrs['MODIFIED']); unset($attrs['dn']); - $ldap->cd("cn=".$this->cn.",".$this->dhcpParentNode); + $ldap->cd($dn); $res = $ldap->add($attrs); # print_a($attrs); # print("cn=".$this->cn.",".$this->dhcpParentNode); -- 2.30.2