Code

Apply fix for #4271
authorpsc <psc@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 29 Apr 2010 11:48:32 +0000 (11:48 +0000)
committerpsc <psc@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 29 Apr 2010 11:48:32 +0000 (11:48 +0000)
When adding targets for event generation store mac, name and
object group membership to the structure and use it, to display
it in the event target listing.

git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6-lhm@17931 594d385d-05f5-0310-b6e9-bd551577e9d8

trunk/gosa-core/include/class_gosaSupportDaemon.inc
trunk/gosa-plugins/goto/addons/goto/events/class_DaemonEvent.inc
trunk/gosa-plugins/goto/addons/goto/events/class_EventTargetAddList.inc
trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po
trunk/gosa-plugins/goto/locale/messages.po
trunk/gosa-plugins/systems/admin/systems/class_systemManagement.inc

index cd776aa59e0f75be04709a367889b75433ac79f4..af297df05da0b8655b465b1e022912d05f46f949 100644 (file)
@@ -986,6 +986,10 @@ class gosaSupportDaemon
       /* Append an entry for each target 
        */
       foreach($targets as $target){
+        if (is_array($target)) {
+            $target = $target['mac'];
+        }
+
         if(!$skip_add_mac){
           $data['macaddress'] = $target;
         }
index e46fd57e5b002ebf0dc45237afc3d421a93c87e6..b255b1a2d50e922bc4aae0fdd53a058cf35b6d36 100644 (file)
@@ -255,8 +255,22 @@ class DaemonEvent
     $this->target_list_used = TRUE;
     $divlist = new divSelectBox("EventTargets");
     foreach($this->a_targets as $key => $target){
+      $string = "";
+      if (is_array($target) && isset($target['cn'])) {
+          $string = $target['cn'];
+      }
+      if (is_array($target) && isset($target['ogroup'])) {
+        $title = sprintf(_("Added via object group '%s'"), $target['ogroup']);
+        $string .= sprintf("<img src='plugins/ogroups/images/select_ogroup.png' title=\"%s\">", $title);
+      }
+      if (is_array($target) && isset($target['mac'])) {
+        $string .= " - " . $target['mac'];
+      }else {
+        $string = $target;
+      }
+
       $divlist->AddEntry(array(
-            array("string"  => $target),
+            array("string"  => $string),
             array("string"  => "<input type='image' src='images/lists/trash.png' title='"._("Remove")."' name='del_target_".$key."'>",
               "attach"  => "style='width:20px; border-right:0px;'")
             ));
index 88f80a42a35f027e3ea0996aec651347fd9e9fcf..fdd05677343ab08948b8a89efccba27f03f1dc74 100644 (file)
@@ -199,17 +199,18 @@ class EventTargetAddList extends MultiSelectWindow
     $a_targets = array();
     foreach($this->list_get_selected_items() as $id){
       if(in_array("gosaGroupOfNames",$this->_target_list[$id]['objectClass'])){
+        $object_group = $this->_target_list[$id]['cn'][0];
         foreach($this->_target_list[$id]['member'] as $mem_dn){
           if(isset($this->workstation_list[$mem_dn])){
-            $a_targets[] = $this->workstation_list[$mem_dn]['macAddress'][0];
+            $a_targets[] = array( "mac" => $this->workstation_list[$mem_dn]['macAddress'][0], "cn" => $this->workstation_list[$mem_dn]['cn'][0], "ogroup" => $object_group);
           }
           if(isset($this->server_list[$mem_dn])){
-            $a_targets[] = $this->server_list[$mem_dn]['macAddress'][0];
+            $a_targets[] = array( "mac" => $this->server_list[$mem_dn]['macAddress'][0], "cn" => $this->server_list[$mem_dn]['cn'][0], "ogroup" => $object_group);
           }
         }
       }else{
         if(isset($this->_target_list[$id]['macAddress'][0])){
-          $a_targets[] = $this->_target_list[$id]['macAddress'][0];
+          $a_targets[] = array( "mac" => $this->_target_list[$id]['macAddress'][0], "cn" => $this->_target_list[$id]['cn'][0]);
         }
       }
     }
index be9483b3802e42305f5b44c42e140ffd6f98a6dd..03b6e9f429045ddac1ea134ad51770173388be02 100644 (file)
@@ -13,7 +13,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: messages\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2010-04-26 16:58+0200\n"
+"POT-Creation-Date: 2010-04-27 11:46+0200\n"
 "PO-Revision-Date: 2008-12-04 11:18+0100\n"
 "Last-Translator: Cajus Pollmeier <pollmeier@gonicus.de>\n"
 "Language-Team: deutsch <de@li.org>\n"
@@ -120,7 +120,7 @@ msgstr "Name"
 #: admin/applications/class_applicationGeneric.inc:623
 #: personal/environment/class_logonManagementDialog.inc:125
 #: personal/environment/logonManagement.tpl:17
-#: addons/goto/class_gotomasses.inc:956
+#: addons/goto/class_gotomasses.inc:912
 msgid "Description"
 msgstr "Beschreibung"
 
@@ -173,10 +173,10 @@ msgstr "Lieferanten-ID"
 #: personal/environment/class_environment.inc:865
 #: personal/environment/class_environment.inc:916
 #: personal/environment/class_environment.inc:1012
-#: addons/goto/class_gotomasses.inc:174 addons/goto/class_gotomasses.inc:560
-#: addons/goto/class_gotomasses.inc:691 addons/goto/class_gotomasses.inc:727
-#: addons/goto/class_gotomasses.inc:771 addons/goto/class_gotomasses.inc:775
-#: addons/goto/class_gotomasses.inc:811 addons/goto/class_gotomasses.inc:855
+#: addons/goto/class_gotomasses.inc:174 addons/goto/class_gotomasses.inc:516
+#: addons/goto/class_gotomasses.inc:647 addons/goto/class_gotomasses.inc:683
+#: addons/goto/class_gotomasses.inc:727 addons/goto/class_gotomasses.inc:731
+#: addons/goto/class_gotomasses.inc:767 addons/goto/class_gotomasses.inc:811
 #: addons/goto/class_target_list.inc:250 addons/goto/class_target_list.inc:254
 #: addons/goto/class_gotoLogView.inc:58 addons/goto/class_gotoLogView.inc:207
 msgid "Error"
@@ -357,7 +357,7 @@ msgstr "Abteilung"
 #: admin/mimetypes/class_divListMimeTypes.inc:109
 #: admin/applications/class_divListApplication.inc:52
 #: admin/applications/class_divListApplication.inc:107
-#: addons/goto/class_gotomasses.inc:401
+#: addons/goto/class_gotomasses.inc:357
 msgid "Actions"
 msgstr "Aktionen"
 
@@ -387,7 +387,7 @@ msgstr "Übertragen"
 #: admin/mimetypes/class_divListMimeTypes.inc:114
 #: admin/systems/goto/chooser.tpl:16
 #: admin/applications/class_divListApplication.inc:111
-#: addons/goto/class_gotomasses.inc:402
+#: addons/goto/class_gotomasses.inc:358
 msgid "Create"
 msgstr "Anlegen"
 
@@ -402,9 +402,9 @@ msgstr "Anlegen"
 #: admin/applications/class_applicationParameters.inc:122
 #: admin/applications/class_divListApplication.inc:120
 #: personal/environment/environment.tpl:238
-#: addons/goto/events/class_DaemonEvent.inc:260
-#: addons/goto/class_gotomasses.inc:269 addons/goto/class_gotomasses.inc:412
-#: addons/goto/class_gotomasses.inc:520 addons/goto/class_gotomasses.inc:524
+#: addons/goto/events/class_DaemonEvent.inc:274
+#: addons/goto/class_gotomasses.inc:269 addons/goto/class_gotomasses.inc:368
+#: addons/goto/class_gotomasses.inc:476 addons/goto/class_gotomasses.inc:480
 msgid "Remove"
 msgstr "Entfernen"
 
@@ -739,12 +739,12 @@ msgid "Folder"
 msgstr "Verzeichnis"
 
 #: admin/groups/apps/app_list.tpl:82 admin/groups/apps/app_list.tpl:103
-#: admin/groups/apps/app_list.tpl:128 addons/goto/class_gotomasses.inc:468
+#: admin/groups/apps/app_list.tpl:128 addons/goto/class_gotomasses.inc:424
 msgid "Move up"
 msgstr "Nach oben bewegen"
 
 #: admin/groups/apps/app_list.tpl:84 admin/groups/apps/app_list.tpl:105
-#: admin/groups/apps/app_list.tpl:130 addons/goto/class_gotomasses.inc:470
+#: admin/groups/apps/app_list.tpl:130 addons/goto/class_gotomasses.inc:426
 msgid "Move down"
 msgstr "Nach unten bewegen"
 
@@ -752,7 +752,7 @@ msgstr "Nach unten bewegen"
 #: admin/systems/goto/printer.tpl:79
 #: admin/systems/services/shares/goShareServer.tpl:17
 #: personal/environment/environment.tpl:274
-#: addons/goto/class_gotomasses.inc:505
+#: addons/goto/class_gotomasses.inc:461
 msgid "Edit"
 msgstr "Bearbeiten"
 
@@ -1003,7 +1003,7 @@ msgstr ""
 "Wählen Sie den Server, der zur Zeit-Synchronisation genutzt werden soll"
 
 #: admin/systems/goto/terminal.tpl:156 admin/systems/goto/workstation.tpl:130
-#: admin/ogroups/goto/termgroup.tpl:112 addons/goto/class_gotomasses.inc:451
+#: admin/ogroups/goto/termgroup.tpl:112 addons/goto/class_gotomasses.inc:407
 msgid "Action"
 msgstr "Aktion"
 
@@ -1016,7 +1016,7 @@ msgstr "Wählen Sie die auszuführende Aktion für dieses Terminal"
 #: admin/systems/goto/workstation.tpl:150 admin/applications/generic.tpl:24
 #: admin/applications/class_applicationGeneric.inc:440
 #: admin/applications/class_applicationGeneric.inc:624
-#: admin/ogroups/goto/termgroup.tpl:125 addons/goto/class_gotomasses.inc:419
+#: admin/ogroups/goto/termgroup.tpl:125 addons/goto/class_gotomasses.inc:375
 msgid "Execute"
 msgstr "Ausführen"
 
@@ -1080,7 +1080,7 @@ msgstr "System-Informationen"
 
 #: admin/systems/goto/class_SelectDeviceType.inc:39
 #: admin/systems/goto/class_workstationGeneric.inc:739
-#: addons/goto/events/class_EventTargetAddList.inc:343
+#: addons/goto/events/class_EventTargetAddList.inc:344
 #: addons/goto/class_target_list.inc:203
 msgid "Workstation"
 msgstr "Arbeitsstation"
@@ -1094,7 +1094,7 @@ msgstr "Terminal"
 #: admin/systems/goto/class_SelectDeviceType.inc:39
 #: admin/systems/services/nfs/servnfs.tpl:39
 #: personal/environment/environment.tpl:135
-#: addons/goto/events/class_EventTargetAddList.inc:286
+#: addons/goto/events/class_EventTargetAddList.inc:287
 #: addons/goto/class_target_list.inc:201
 msgid "Server"
 msgstr "Server"
@@ -1153,14 +1153,14 @@ msgstr "Andere Netzwerk-Komponente"
 #: admin/systems/goto/class_terminalGeneric.inc:139
 #: admin/systems/goto/class_terminalGeneric.inc:289
 #: admin/systems/goto/class_terminalGeneric.inc:301
+#: admin/systems/goto/class_workstationService.inc:192
+#: admin/systems/goto/class_workstationService.inc:193
+#: admin/systems/goto/class_workstationService.inc:194
+#: admin/systems/goto/class_workstationService.inc:195
+#: admin/systems/goto/class_workstationService.inc:196
+#: admin/systems/goto/class_workstationService.inc:197
 #: admin/systems/goto/class_workstationService.inc:198
 #: admin/systems/goto/class_workstationService.inc:199
-#: admin/systems/goto/class_workstationService.inc:200
-#: admin/systems/goto/class_workstationService.inc:201
-#: admin/systems/goto/class_workstationService.inc:202
-#: admin/systems/goto/class_workstationService.inc:203
-#: admin/systems/goto/class_workstationService.inc:204
-#: admin/systems/goto/class_workstationService.inc:205
 #: admin/systems/goto/class_workstationService.inc:539
 #: admin/systems/goto/class_workstationService.inc:543
 #: admin/systems/goto/class_workstationService.inc:546
@@ -1436,7 +1436,7 @@ msgstr "von Gruppe übernehmen"
 #: admin/systems/goto/terminalStartup.tpl:14
 #: admin/systems/goto/terminalService.tpl:184
 #: admin/systems/goto/workstationStartup.tpl:36
-#: addons/goto/class_gotomasses.inc:436
+#: addons/goto/class_gotomasses.inc:392
 msgid "Reload"
 msgstr "Neu laden"
 
@@ -1645,7 +1645,7 @@ msgstr "Ihr Browser unterstützt keine iframes."
 #: admin/systems/goto/class_terminalGeneric.inc:123
 #: admin/systems/goto/class_workstationGeneric.inc:143
 #: admin/ogroups/goto/class_termgroup.inc:53
-#: addons/goto/class_gotomasses.inc:574
+#: addons/goto/class_gotomasses.inc:530
 msgid "Locked"
 msgstr "Gesperrt"
 
@@ -1665,7 +1665,8 @@ msgstr "Aktiv"
 #: admin/systems/goto/class_workstationGeneric.inc:222
 #: admin/systems/goto/class_workstationGeneric.inc:645
 #: admin/ogroups/goto/class_termgroup.inc:217
-#: addons/goto/class_gotomasses.inc:350 addons/goto/class_gotomasses.inc:363
+#: addons/goto/events/class_DaemonEvent.inc:454
+#: addons/goto/events/class_DaemonEvent.inc:465
 #: addons/goto/class_goto_import_file.inc:124
 msgid "Service infrastructure"
 msgstr "Dienst-Infrastruktur"
@@ -2094,7 +2095,7 @@ msgstr "Wählen Sie eine Objektgruppe als Vorlageobjekt"
 
 #: admin/systems/goto/SelectDeviceType.tpl:37
 #: addons/goto/events/class_EventTargetAddUsersList.inc:181
-#: addons/goto/events/class_EventTargetAddList.inc:441
+#: addons/goto/events/class_EventTargetAddList.inc:442
 #: addons/goto/class_target_list.inc:205 addons/goto/goto_import_file.tpl:40
 msgid "Object group"
 msgstr "Objektgruppe"
@@ -2917,7 +2918,7 @@ msgstr "Konfiguration bei jedem Start ersetzen"
 msgid "Script"
 msgstr "Skript"
 
-#: admin/applications/generic.tpl:139 addons/goto/class_gotomasses.inc:411
+#: admin/applications/generic.tpl:139 addons/goto/class_gotomasses.inc:367
 #: addons/goto/goto_import_file.tpl:84
 #: addons/goto/class_goto_import_file.inc:29
 #: addons/goto/class_goto_import_file.inc:89
@@ -3382,7 +3383,7 @@ msgstr "Es sind keine Protokolle für dieses System verfügbar!"
 #: addons/goto/events/DaemonEvent_reinstall.tpl:9
 #: addons/goto/events/DaemonEvent_wakeup.tpl:9
 #: addons/goto/events/DaemonEvent_rescan.tpl:9
-#: addons/goto/class_gotomasses.inc:447
+#: addons/goto/class_gotomasses.inc:403
 msgid "Schedule"
 msgstr "Plan"
 
@@ -3439,7 +3440,7 @@ msgstr "ID"
 #: addons/goto/events/DaemonEvent_wakeup.tpl:44
 #: addons/goto/events/DaemonEvent_activate.tpl:44
 #: addons/goto/events/DaemonEvent_rescan.tpl:44
-#: addons/goto/class_gotomasses.inc:449
+#: addons/goto/class_gotomasses.inc:405
 msgid "Status"
 msgstr "Status"
 
@@ -3481,7 +3482,7 @@ msgstr "Ergebnis"
 #: addons/goto/events/DaemonEvent_wakeup.tpl:52
 #: addons/goto/events/DaemonEvent_activate.tpl:52
 #: addons/goto/events/DaemonEvent_rescan.tpl:52
-#: addons/goto/class_gotomasses.inc:444
+#: addons/goto/class_gotomasses.inc:400
 msgid "Target"
 msgstr "Ziel"
 
@@ -3533,7 +3534,11 @@ msgstr "Dieser Auftrag hat keine Vorlage!"
 msgid "Create '%s' job"
 msgstr "Erstelle '%s'-Vorgang"
 
-#: addons/goto/events/class_DaemonEvent.inc:264
+#: addons/goto/events/class_DaemonEvent.inc:263
+msgid "Added via object group '%s'"
+msgstr "Via Objektgruppe '%s' hinzugefügt"
+
+#: addons/goto/events/class_DaemonEvent.inc:278
 msgid "Add"
 msgstr "Hinzufügen"
 
@@ -3752,99 +3757,99 @@ msgstr ""
 "Die folgenden Aufträge konnten nicht gelöscht werden, sie müssen abgebrochen "
 "werden: %s"
 
-#: addons/goto/class_gotomasses.inc:396
+#: addons/goto/class_gotomasses.inc:352
 msgid "This menu allows you to remove and change the properties of GOsa tasks."
 msgstr ""
 "Dieses Menü erlaubt es Ihnen, GOsa-Aufgaben zu entfernen oder die "
 "Eigenschaften zu verändern."
 
-#: addons/goto/class_gotomasses.inc:397
+#: addons/goto/class_gotomasses.inc:353
 msgid "List of queued jobs"
 msgstr "Liste der geplanten Vorgänge"
 
-#: addons/goto/class_gotomasses.inc:416
+#: addons/goto/class_gotomasses.inc:372
 msgid "Resume"
 msgstr "Fortsetzen"
 
-#: addons/goto/class_gotomasses.inc:417
+#: addons/goto/class_gotomasses.inc:373
 msgid "Pause"
 msgstr "Pause"
 
-#: addons/goto/class_gotomasses.inc:418
+#: addons/goto/class_gotomasses.inc:374
 msgid "Abort"
 msgstr "Abbrechen"
 
-#: addons/goto/class_gotomasses.inc:445
+#: addons/goto/class_gotomasses.inc:401
 msgid "Task"
 msgstr "Vorgang"
 
-#: addons/goto/class_gotomasses.inc:477
+#: addons/goto/class_gotomasses.inc:433
 msgid "Pause job"
 msgstr "Vorgang pausieren"
 
-#: addons/goto/class_gotomasses.inc:484
+#: addons/goto/class_gotomasses.inc:440
 msgid "Resume job"
 msgstr "Vorgang fortsetzen"
 
-#: addons/goto/class_gotomasses.inc:491
+#: addons/goto/class_gotomasses.inc:447
 msgid "Execute now"
 msgstr "Sofort ausführen"
 
-#: addons/goto/class_gotomasses.inc:498
+#: addons/goto/class_gotomasses.inc:454
 msgid "View logs"
 msgstr "Protokolle einsehen"
 
-#: addons/goto/class_gotomasses.inc:513
+#: addons/goto/class_gotomasses.inc:469
 msgid "Abort job"
 msgstr "Vorgang abbrechen"
 
-#: addons/goto/class_gotomasses.inc:557
+#: addons/goto/class_gotomasses.inc:513
 msgid "Waiting"
 msgstr "Wartend"
 
-#: addons/goto/class_gotomasses.inc:563
+#: addons/goto/class_gotomasses.inc:519
 msgid "Processed"
 msgstr "Durchgeführt"
 
-#: addons/goto/class_gotomasses.inc:578
+#: addons/goto/class_gotomasses.inc:534
 msgid "Detection"
 msgstr "Erkennung"
 
-#: addons/goto/class_gotomasses.inc:586
+#: addons/goto/class_gotomasses.inc:542
 msgid "in progress"
 msgstr "in Bearbeitung"
 
-#: addons/goto/class_gotomasses.inc:599
+#: addons/goto/class_gotomasses.inc:555
 msgid "immediately"
 msgstr "sofort"
 
-#: addons/goto/class_gotomasses.inc:691 addons/goto/class_gotomasses.inc:771
-#: addons/goto/class_gotomasses.inc:811
+#: addons/goto/class_gotomasses.inc:647 addons/goto/class_gotomasses.inc:727
+#: addons/goto/class_gotomasses.inc:767
 #, php-format
 msgid "Cannot update queue entry: %s"
 msgstr "Kann Warteschlangeneintrag nicht aktualisieren: %s"
 
-#: addons/goto/class_gotomasses.inc:727
+#: addons/goto/class_gotomasses.inc:683
 #, php-format
 msgid "Cannot update queue entries."
 msgstr "Kann Warteschlangeneinträge nicht aktualisieren."
 
-#: addons/goto/class_gotomasses.inc:776
+#: addons/goto/class_gotomasses.inc:732
 #, php-format
 msgid "Required class '%s' cannot be found: job not aborted!"
 msgstr ""
 "Die erforderliche Klasse '%s' wurde nicht gefunden: Auftrag abgebrochen!"
 
-#: addons/goto/class_gotomasses.inc:855
+#: addons/goto/class_gotomasses.inc:811
 #, php-format
 msgid "Cannot load queue entries: %s"
 msgstr "Kann Warteschlangeneinträge nicht laden: %s"
 
-#: addons/goto/class_gotomasses.inc:949 addons/goto/class_gotomasses.inc:955
+#: addons/goto/class_gotomasses.inc:905 addons/goto/class_gotomasses.inc:911
 msgid "System deployment"
 msgstr "System-Verteilung"
 
-#: addons/goto/class_gotomasses.inc:950
+#: addons/goto/class_gotomasses.inc:906
 msgid "Provide a mechanism to automatically activate systems"
 msgstr "Stelle einen Mechanismus bereit um Systemen automatisch zu aktivieren"
 
index 0f2a3711d57d6b9aad6ae413ea491c6ddd5aeaac..9863a1462eb3a5bc662394dd54249748f96ee875 100644 (file)
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2010-04-26 16:58+0200\n"
+"POT-Creation-Date: 2010-04-27 11:46+0200\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -114,7 +114,7 @@ msgstr ""
 #: admin/applications/class_applicationGeneric.inc:623
 #: personal/environment/class_logonManagementDialog.inc:125
 #: personal/environment/logonManagement.tpl:17
-#: addons/goto/class_gotomasses.inc:956
+#: addons/goto/class_gotomasses.inc:912
 msgid "Description"
 msgstr ""
 
@@ -166,10 +166,10 @@ msgstr ""
 #: personal/environment/class_environment.inc:865
 #: personal/environment/class_environment.inc:916
 #: personal/environment/class_environment.inc:1012
-#: addons/goto/class_gotomasses.inc:174 addons/goto/class_gotomasses.inc:560
-#: addons/goto/class_gotomasses.inc:691 addons/goto/class_gotomasses.inc:727
-#: addons/goto/class_gotomasses.inc:771 addons/goto/class_gotomasses.inc:775
-#: addons/goto/class_gotomasses.inc:811 addons/goto/class_gotomasses.inc:855
+#: addons/goto/class_gotomasses.inc:174 addons/goto/class_gotomasses.inc:516
+#: addons/goto/class_gotomasses.inc:647 addons/goto/class_gotomasses.inc:683
+#: addons/goto/class_gotomasses.inc:727 addons/goto/class_gotomasses.inc:731
+#: addons/goto/class_gotomasses.inc:767 addons/goto/class_gotomasses.inc:811
 #: addons/goto/class_target_list.inc:250 addons/goto/class_target_list.inc:254
 #: addons/goto/class_gotoLogView.inc:58 addons/goto/class_gotoLogView.inc:207
 msgid "Error"
@@ -350,7 +350,7 @@ msgstr ""
 #: admin/mimetypes/class_divListMimeTypes.inc:109
 #: admin/applications/class_divListApplication.inc:52
 #: admin/applications/class_divListApplication.inc:107
-#: addons/goto/class_gotomasses.inc:401
+#: addons/goto/class_gotomasses.inc:357
 msgid "Actions"
 msgstr ""
 
@@ -380,7 +380,7 @@ msgstr ""
 #: admin/mimetypes/class_divListMimeTypes.inc:114
 #: admin/systems/goto/chooser.tpl:16
 #: admin/applications/class_divListApplication.inc:111
-#: addons/goto/class_gotomasses.inc:402
+#: addons/goto/class_gotomasses.inc:358
 msgid "Create"
 msgstr ""
 
@@ -395,9 +395,9 @@ msgstr ""
 #: admin/applications/class_applicationParameters.inc:122
 #: admin/applications/class_divListApplication.inc:120
 #: personal/environment/environment.tpl:238
-#: addons/goto/events/class_DaemonEvent.inc:260
-#: addons/goto/class_gotomasses.inc:269 addons/goto/class_gotomasses.inc:412
-#: addons/goto/class_gotomasses.inc:520 addons/goto/class_gotomasses.inc:524
+#: addons/goto/events/class_DaemonEvent.inc:274
+#: addons/goto/class_gotomasses.inc:269 addons/goto/class_gotomasses.inc:368
+#: addons/goto/class_gotomasses.inc:476 addons/goto/class_gotomasses.inc:480
 msgid "Remove"
 msgstr ""
 
@@ -724,12 +724,12 @@ msgid "Folder"
 msgstr ""
 
 #: admin/groups/apps/app_list.tpl:82 admin/groups/apps/app_list.tpl:103
-#: admin/groups/apps/app_list.tpl:128 addons/goto/class_gotomasses.inc:468
+#: admin/groups/apps/app_list.tpl:128 addons/goto/class_gotomasses.inc:424
 msgid "Move up"
 msgstr ""
 
 #: admin/groups/apps/app_list.tpl:84 admin/groups/apps/app_list.tpl:105
-#: admin/groups/apps/app_list.tpl:130 addons/goto/class_gotomasses.inc:470
+#: admin/groups/apps/app_list.tpl:130 addons/goto/class_gotomasses.inc:426
 msgid "Move down"
 msgstr ""
 
@@ -737,7 +737,7 @@ msgstr ""
 #: admin/systems/goto/printer.tpl:79
 #: admin/systems/services/shares/goShareServer.tpl:17
 #: personal/environment/environment.tpl:274
-#: addons/goto/class_gotomasses.inc:505
+#: addons/goto/class_gotomasses.inc:461
 msgid "Edit"
 msgstr ""
 
@@ -985,7 +985,7 @@ msgid "Choose server to use for synchronizing time"
 msgstr ""
 
 #: admin/systems/goto/terminal.tpl:156 admin/systems/goto/workstation.tpl:130
-#: admin/ogroups/goto/termgroup.tpl:112 addons/goto/class_gotomasses.inc:451
+#: admin/ogroups/goto/termgroup.tpl:112 addons/goto/class_gotomasses.inc:407
 msgid "Action"
 msgstr ""
 
@@ -998,7 +998,7 @@ msgstr ""
 #: admin/systems/goto/workstation.tpl:150 admin/applications/generic.tpl:24
 #: admin/applications/class_applicationGeneric.inc:440
 #: admin/applications/class_applicationGeneric.inc:624
-#: admin/ogroups/goto/termgroup.tpl:125 addons/goto/class_gotomasses.inc:419
+#: admin/ogroups/goto/termgroup.tpl:125 addons/goto/class_gotomasses.inc:375
 msgid "Execute"
 msgstr ""
 
@@ -1060,7 +1060,7 @@ msgstr ""
 
 #: admin/systems/goto/class_SelectDeviceType.inc:39
 #: admin/systems/goto/class_workstationGeneric.inc:739
-#: addons/goto/events/class_EventTargetAddList.inc:343
+#: addons/goto/events/class_EventTargetAddList.inc:344
 #: addons/goto/class_target_list.inc:203
 msgid "Workstation"
 msgstr ""
@@ -1074,7 +1074,7 @@ msgstr ""
 #: admin/systems/goto/class_SelectDeviceType.inc:39
 #: admin/systems/services/nfs/servnfs.tpl:39
 #: personal/environment/environment.tpl:135
-#: addons/goto/events/class_EventTargetAddList.inc:286
+#: addons/goto/events/class_EventTargetAddList.inc:287
 #: addons/goto/class_target_list.inc:201
 msgid "Server"
 msgstr ""
@@ -1127,14 +1127,14 @@ msgstr ""
 #: admin/systems/goto/class_terminalGeneric.inc:139
 #: admin/systems/goto/class_terminalGeneric.inc:289
 #: admin/systems/goto/class_terminalGeneric.inc:301
+#: admin/systems/goto/class_workstationService.inc:192
+#: admin/systems/goto/class_workstationService.inc:193
+#: admin/systems/goto/class_workstationService.inc:194
+#: admin/systems/goto/class_workstationService.inc:195
+#: admin/systems/goto/class_workstationService.inc:196
+#: admin/systems/goto/class_workstationService.inc:197
 #: admin/systems/goto/class_workstationService.inc:198
 #: admin/systems/goto/class_workstationService.inc:199
-#: admin/systems/goto/class_workstationService.inc:200
-#: admin/systems/goto/class_workstationService.inc:201
-#: admin/systems/goto/class_workstationService.inc:202
-#: admin/systems/goto/class_workstationService.inc:203
-#: admin/systems/goto/class_workstationService.inc:204
-#: admin/systems/goto/class_workstationService.inc:205
 #: admin/systems/goto/class_workstationService.inc:539
 #: admin/systems/goto/class_workstationService.inc:543
 #: admin/systems/goto/class_workstationService.inc:546
@@ -1398,7 +1398,7 @@ msgstr ""
 #: admin/systems/goto/terminalStartup.tpl:14
 #: admin/systems/goto/terminalService.tpl:184
 #: admin/systems/goto/workstationStartup.tpl:36
-#: addons/goto/class_gotomasses.inc:436
+#: addons/goto/class_gotomasses.inc:392
 msgid "Reload"
 msgstr ""
 
@@ -1603,7 +1603,7 @@ msgstr ""
 #: admin/systems/goto/class_terminalGeneric.inc:123
 #: admin/systems/goto/class_workstationGeneric.inc:143
 #: admin/ogroups/goto/class_termgroup.inc:53
-#: addons/goto/class_gotomasses.inc:574
+#: addons/goto/class_gotomasses.inc:530
 msgid "Locked"
 msgstr ""
 
@@ -1623,7 +1623,8 @@ msgstr ""
 #: admin/systems/goto/class_workstationGeneric.inc:222
 #: admin/systems/goto/class_workstationGeneric.inc:645
 #: admin/ogroups/goto/class_termgroup.inc:217
-#: addons/goto/class_gotomasses.inc:350 addons/goto/class_gotomasses.inc:363
+#: addons/goto/events/class_DaemonEvent.inc:454
+#: addons/goto/events/class_DaemonEvent.inc:465
 #: addons/goto/class_goto_import_file.inc:124
 msgid "Service infrastructure"
 msgstr ""
@@ -2033,7 +2034,7 @@ msgstr ""
 
 #: admin/systems/goto/SelectDeviceType.tpl:37
 #: addons/goto/events/class_EventTargetAddUsersList.inc:181
-#: addons/goto/events/class_EventTargetAddList.inc:441
+#: addons/goto/events/class_EventTargetAddList.inc:442
 #: addons/goto/class_target_list.inc:205 addons/goto/goto_import_file.tpl:40
 msgid "Object group"
 msgstr ""
@@ -2830,7 +2831,7 @@ msgstr ""
 msgid "Script"
 msgstr ""
 
-#: admin/applications/generic.tpl:139 addons/goto/class_gotomasses.inc:411
+#: admin/applications/generic.tpl:139 addons/goto/class_gotomasses.inc:367
 #: addons/goto/goto_import_file.tpl:84
 #: addons/goto/class_goto_import_file.inc:29
 #: addons/goto/class_goto_import_file.inc:89
@@ -3281,7 +3282,7 @@ msgstr ""
 #: addons/goto/events/DaemonEvent_reinstall.tpl:9
 #: addons/goto/events/DaemonEvent_wakeup.tpl:9
 #: addons/goto/events/DaemonEvent_rescan.tpl:9
-#: addons/goto/class_gotomasses.inc:447
+#: addons/goto/class_gotomasses.inc:403
 msgid "Schedule"
 msgstr ""
 
@@ -3338,7 +3339,7 @@ msgstr ""
 #: addons/goto/events/DaemonEvent_wakeup.tpl:44
 #: addons/goto/events/DaemonEvent_activate.tpl:44
 #: addons/goto/events/DaemonEvent_rescan.tpl:44
-#: addons/goto/class_gotomasses.inc:449
+#: addons/goto/class_gotomasses.inc:405
 msgid "Status"
 msgstr ""
 
@@ -3380,7 +3381,7 @@ msgstr ""
 #: addons/goto/events/DaemonEvent_wakeup.tpl:52
 #: addons/goto/events/DaemonEvent_activate.tpl:52
 #: addons/goto/events/DaemonEvent_rescan.tpl:52
-#: addons/goto/class_gotomasses.inc:444
+#: addons/goto/class_gotomasses.inc:400
 msgid "Target"
 msgstr ""
 
@@ -3432,7 +3433,12 @@ msgstr ""
 msgid "Create '%s' job"
 msgstr ""
 
-#: addons/goto/events/class_DaemonEvent.inc:264
+#: addons/goto/events/class_DaemonEvent.inc:263
+#, php-format
+msgid "Added via object group '%s'"
+msgstr ""
+
+#: addons/goto/events/class_DaemonEvent.inc:278
 msgid "Add"
 msgstr ""
 
@@ -3643,96 +3649,96 @@ msgstr ""
 msgid "The following jobs couldn't be deleted, they have to be aborted: %s"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:396
+#: addons/goto/class_gotomasses.inc:352
 msgid "This menu allows you to remove and change the properties of GOsa tasks."
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:397
+#: addons/goto/class_gotomasses.inc:353
 msgid "List of queued jobs"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:416
+#: addons/goto/class_gotomasses.inc:372
 msgid "Resume"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:417
+#: addons/goto/class_gotomasses.inc:373
 msgid "Pause"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:418
+#: addons/goto/class_gotomasses.inc:374
 msgid "Abort"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:445
+#: addons/goto/class_gotomasses.inc:401
 msgid "Task"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:477
+#: addons/goto/class_gotomasses.inc:433
 msgid "Pause job"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:484
+#: addons/goto/class_gotomasses.inc:440
 msgid "Resume job"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:491
+#: addons/goto/class_gotomasses.inc:447
 msgid "Execute now"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:498
+#: addons/goto/class_gotomasses.inc:454
 msgid "View logs"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:513
+#: addons/goto/class_gotomasses.inc:469
 msgid "Abort job"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:557
+#: addons/goto/class_gotomasses.inc:513
 msgid "Waiting"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:563
+#: addons/goto/class_gotomasses.inc:519
 msgid "Processed"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:578
+#: addons/goto/class_gotomasses.inc:534
 msgid "Detection"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:586
+#: addons/goto/class_gotomasses.inc:542
 msgid "in progress"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:599
+#: addons/goto/class_gotomasses.inc:555
 msgid "immediately"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:691 addons/goto/class_gotomasses.inc:771
-#: addons/goto/class_gotomasses.inc:811
+#: addons/goto/class_gotomasses.inc:647 addons/goto/class_gotomasses.inc:727
+#: addons/goto/class_gotomasses.inc:767
 #, php-format
 msgid "Cannot update queue entry: %s"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:727
+#: addons/goto/class_gotomasses.inc:683
 #, php-format
 msgid "Cannot update queue entries."
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:776
+#: addons/goto/class_gotomasses.inc:732
 #, php-format
 msgid "Required class '%s' cannot be found: job not aborted!"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:855
+#: addons/goto/class_gotomasses.inc:811
 #, php-format
 msgid "Cannot load queue entries: %s"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:949 addons/goto/class_gotomasses.inc:955
+#: addons/goto/class_gotomasses.inc:905 addons/goto/class_gotomasses.inc:911
 msgid "System deployment"
 msgstr ""
 
-#: addons/goto/class_gotomasses.inc:950
+#: addons/goto/class_gotomasses.inc:906
 msgid "Provide a mechanism to automatically activate systems"
 msgstr ""
 
index 3d9fa94b5dddbd667ceaa34a196c9d2fb2f9f8c5..9f18ef5671c93ba78b721bc92e8cbe13f75e157f 100644 (file)
@@ -784,7 +784,7 @@ class systems extends plugin
       }
 
       if(count($ids) && class_available("DaemonEvent")){
-        $mac= array();
+        $targets = array();
 
         /* Collect target mac addresses */
         $ldap = $this->config->get_ldap_link();
@@ -792,12 +792,12 @@ class systems extends plugin
           $type = $this->get_system_type($this->terminals[$id]);
           if(!in_array($type,array("terminal","server","workstation","opsi_client","winstation "))) continue;
           if(isset($this->terminals[$id]['macAddress'][0])){
-            $mac[] = $this->terminals[$id]['macAddress'][0];
+            $targets[] = array( "mac" => $this->terminals[$id]['macAddress'][0], "cn" => $this->terminals[$id]['cn'][0] );
           }else{
-            $ldap->cat ($this->terminals[$id]['dn'], array("macAddress"));
+            $ldap->cat ($this->terminals[$id]['dn'], array("macAddress", "cn"));
             $attrs= $ldap->fetch();
             if (isset($attrs['macAddress'][0])){
-              $mac[]= $attrs['macAddress'][0];
+              $targets[]= array( "mac" => $attrs['macAddress'][0], "cn" => $attrs['cn'][0] );
             }
           }
         }
@@ -809,14 +809,15 @@ class systems extends plugin
          *  if this entry is currently processing.
          */
         if(preg_match("/trigger_event/",$s_action) && in_array($type,array("DaemonEvent_reinstall","DaemonEvent_update"))){
-          foreach($mac as $key => $mac_address){
+          foreach($targets as $key => $mac_address){
+            $mac_address = $mac_address[0];
             foreach($o_queue->get_entries_by_mac(array($mac_address)) as $entry){
 
               $entry['STATUS'] = strtoupper($entry['STATUS']);
               if($entry['STATUS'] == "PROCESSING" && 
                   isset($events['QUEUED'][$entry['HEADERTAG']]) && 
                   in_array($events['QUEUED'][$entry['HEADERTAG']],array("DaemonEvent_reinstall","DaemonEvent_update"))){
-                unset($mac[$key]);
+                unset($targets[$key]);
 
                 new log("security","systems/".get_class($this),"",array(),"Skip adding 'DaemonEvent::".$type."' for mac '".$mac_address."', there is already a job in progress.");
                 break;
@@ -827,10 +828,10 @@ class systems extends plugin
 
         /* Prepare event to be added 
          */
-        if(count($mac) && isset($events['BY_CLASS'][$type])){
+        if(count($targets) && isset($events['BY_CLASS'][$type])){
           $event = $events['BY_CLASS'][$type];
           $this->systab = new $event['CLASS_NAME']($this->config);
-          $this->systab->add_targets($mac);
+          $this->systab->add_targets($targets);
           if(preg_match("/trigger_event/",$s_action)){
             $this->systab->set_type(TRIGGERED_EVENT);
           }else{