From dc5d06733c6132cbd8f438fe92c30b7e63d74d19 Mon Sep 17 00:00:00 2001 From: psc Date: Fri, 3 Dec 2010 10:25:13 +0000 Subject: [PATCH] Followup patch for #6056 Display a warning message if a workstation is a member of more than one object group. git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6-lhm@20516 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../admin/systems/goto/class_workstationStartup.inc | 12 ++++++++++++ .../goto/locale/de/LC_MESSAGES/messages.po | 8 ++++++++ trunk/gosa-plugins/goto/locale/messages.po | 7 +++++++ 3 files changed, 27 insertions(+) diff --git a/trunk/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc b/trunk/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc index 58fc74ed2..8d54dde92 100644 --- a/trunk/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc +++ b/trunk/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc @@ -81,6 +81,18 @@ class workstartup extends plugin $this->member_of_ogroup = TRUE; $attrs = $ldap->fetch(); $this->o_group_dn = $attrs['dn']; + if ($ldap->count() > 1) { + $ogroups = array(); + array_push($ogroups, $attrs['dn']); + while ($attrs = $ldap->fetch()) { + array_push($ogroups, $attrs['dn']); + } + $str = ""; + foreach($ogroups as $dn) { + $str .= "
  • ".$dn."
  • "; + } + msg_dialog::display(_("Warning"), sprintf(_("This system is member of more than one object group, object group inheritence will not work!")."
    ", $str), WARNING_DIALOG); + } } } diff --git a/trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po b/trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po index 03b6e9f42..b18af3ca4 100644 --- a/trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po +++ b/trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po @@ -1904,6 +1904,14 @@ msgstr "Maus-Typ" msgid "Mouse port" msgstr "Maus-Anschluß" +#: admin/systems/goto/class_workstationStartup.inc:94 +#, php-format +msgid "" +"This system is member of more than one object group, object group " +"inheritence will not work!" +msgstr "Dieses System is Mitglied von mehr als einer Objektgruppe, " +"Vererbung ist nicht möglich!" + #: admin/systems/goto/class_workstationStartup.inc:232 #, php-format msgid "FAI mirror '%s' is not available - setting to mirror 'auto'!" diff --git a/trunk/gosa-plugins/goto/locale/messages.po b/trunk/gosa-plugins/goto/locale/messages.po index 9863a1462..5f2fb11fe 100644 --- a/trunk/gosa-plugins/goto/locale/messages.po +++ b/trunk/gosa-plugins/goto/locale/messages.po @@ -1860,6 +1860,13 @@ msgstr "" msgid "Mouse port" msgstr "" +#: admin/systems/goto/class_workstationStartup.inc:94 +#, php-format +msgid "" +"This system is member of more than one object group, object group " +"inheritence will not work!" +msgstr "" + #: admin/systems/goto/class_workstationStartup.inc:232 #, php-format msgid "FAI mirror '%s' is not available - setting to mirror 'auto'!" -- 2.30.2