summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 718cb91)
raw | patch | inline | side by side (parent: 718cb91)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Sep 2007 09:22:14 +0000 (09:22 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Sep 2007 09:22:14 +0000 (09:22 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7225 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/plugins/admin/systems/class_componentGeneric.inc b/plugins/admin/systems/class_componentGeneric.inc
index 90614de98bfdf32fd4e2a000fee0e9b6388fe02f..9b890a547b10fad692b226665785bd1a4d3df045 100644 (file)
$ldap->search ("(cn=".$this->cn.")", array("cn"));
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
+ if(preg_match("/cn=dhcp,/",$attrs['dn'])){
+ continue;
+ }
if ($attrs['dn'] != $this->orig_dn){
$message[]= sprintf (_("There is already an entry '%s' in the base choosen by you"), $this->cn);
break;
diff --git a/plugins/admin/systems/class_phoneGeneric.inc b/plugins/admin/systems/class_phoneGeneric.inc
index 103f536e6869957c04eec5cb636680511ba7f6ec..fc2ce9d6095333faa52b59a352e0bd8556558ace 100644 (file)
$ldap->search ("(cn=".$this->cn.")", array("cn"));
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
+
+ if(preg_match("/cn=dhcp,/",$attrs['dn'])){
+ continue;
+ }
+
if ($attrs['dn'] != $this->orig_dn){
$message[]= sprintf (_("There is already an entry '%s' in the base choosen by you"), $this->cn);
break;
diff --git a/plugins/admin/systems/class_printGeneric.inc b/plugins/admin/systems/class_printGeneric.inc
index 48c23aade67277be5bfcdffd9eaaae708ad04eee..25a78d57f0c03a984086360dee0e91f56e66a427 100644 (file)
$ldap->ls("(cn=".$this->cn.")","ou=printers,ou=systems,".$this->base, array("cn"));
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
+ if(preg_match("/cn=dhcp,/",$attrs['dn'])){
+ continue;
+ }
if ($attrs['dn'] != $this->orig_dn){
$message[]= sprintf (_("There is already an entry '%s' in the base choosen by you"), $this->cn);
break;
diff --git a/plugins/admin/systems/class_servGeneric.inc b/plugins/admin/systems/class_servGeneric.inc
index f136a1c16c66706210948358ef3a4ec29bce2936..37e4aef73e76c6ffa502a8d1a1f0d2edcc66ab1a 100644 (file)
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
if ($attrs['dn'] != $this->orig_dn){
- if(!preg_match("/,ou=incoming,/",$attrs['dn']) && preg_match("/,ou=servers,ou=systems,/",$attrs['dn'])){
+ if(!preg_match("/cn=dhcp,/",$attrs['dn']) && !preg_match("/,ou=incoming,/",$attrs['dn']) && preg_match("/,ou=servers,ou=systems,/",$attrs['dn'])){
$message[]= sprintf (_("There is already an entry '%s' in the base choosen by you"), $this->cn);
break;
}
diff --git a/plugins/admin/systems/class_terminalGeneric.inc b/plugins/admin/systems/class_terminalGeneric.inc
index ec31c831f4db43b114485a9adcceed55111d48ea..775d95dca4202875202483a68cb8a3f2c9b7d6de 100644 (file)
}
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
- if (preg_match ("/,ou=incoming,/", $ldap->getDN())){
+ if (preg_match("/cn=dhcp,/",$attrs['dn']) || preg_match ("/,ou=incoming,/", $ldap->getDN())){
continue;
} else {
if ($attrs['dn'] != $this->orig_dn){
diff --git a/plugins/admin/systems/class_winGeneric.inc b/plugins/admin/systems/class_winGeneric.inc
index dcf6e205136b094d6d5faf40d5dbe15d2668ca6a..97de3be8bde7509911ed6c24fdd55fe3768d7098 100644 (file)
$ldap->search ("(cn=".$this->cn.")", array("cn"));
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
+ if(preg_match("/cn=dhcp,/",$attrs['dn'])){
+ continue;
+ }
if ($attrs['dn'] != $this->orig_dn){
$message[]= sprintf (_("There is already an entry '%s' in the base choosen by you"), $this->cn);
break;
diff --git a/plugins/admin/systems/class_workstationGeneric.inc b/plugins/admin/systems/class_workstationGeneric.inc
index e3900e931c2e1b098d02dd8be6be11886fd7e4c1..4fbba785479041a6a2905e24e5678af40bff1f43 100644 (file)
}
if ($ldap->count() != 0){
while ($attrs= $ldap->fetch()){
- if (preg_match ("/,ou=incoming,/", $ldap->getDN())){
+ if (preg_match("/cn=dhcp,/",$attrs['dn']) || preg_match ("/,ou=incoming,/", $ldap->getDN())){
continue;
} else {
if ($attrs['dn'] != $this->orig_dn){