From 7f08ea599710ed2faad33ede203b1e9903b7f8dd Mon Sep 17 00:00:00 2001 From: psc Date: Fri, 26 Feb 2010 10:58:22 +0000 Subject: [PATCH] Apply fix for #2852 - Let gosa-si-client determine weither FAI operation is an installation or a softupdate and additionally send this info to the server. - Let gosa-si-client call save_fai_log on "TASKBEGIN savelog" instead of "TASKBEGIN finish". This fixes the problem that the save function were not called when running a soft-update. - In gosa-si-server handle the new fai_action field when receiving logfiles so that softupdate logs are stored in different directories than installation logs. - Add logic to the code that gets FAI logfiles from gosa-si to detect weither a softupdate or installation log is received and set an attribute in the result array accordingly. - When viewing install logs in Gosa show a new column with the FAI operation the files belong to. git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6-lhm@15739 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../include/class_gosaSupportDaemon.inc | 6 +- .../goto/addons/goto/class_gotoLogView.inc | 64 ++++++--- .../goto/locale/de/LC_MESSAGES/messages.po | 136 +++++++++--------- trunk/gosa-plugins/goto/locale/messages.po | 136 +++++++++--------- trunk/gosa-si/gosa-si-client | 11 +- trunk/gosa-si/server/events/clMessages.pm | 3 +- 6 files changed, 205 insertions(+), 151 deletions(-) diff --git a/trunk/gosa-core/include/class_gosaSupportDaemon.inc b/trunk/gosa-core/include/class_gosaSupportDaemon.inc index 33e841885..cd776aa59 100644 --- a/trunk/gosa-core/include/class_gosaSupportDaemon.inc +++ b/trunk/gosa-core/include/class_gosaSupportDaemon.inc @@ -1772,7 +1772,11 @@ class gosaSupportDaemon $ret[$mac][$log_date] = array(); $res = $this->_send($xml_msg2,TRUE); - $ret[$mac][$log_date]['DATE_STR'] = $log_date; + $ret[$mac][$log_date]['DATE_STR'] = $log_date; + /* Determine FAI action */ + $fai_action = split('_', $ret[$mac][$log_date]['DATE_STR']); + $fai_action = $fai_action[0]; + $ret[$mac][$log_date]['FAI_ACTION'] = $fai_action; $ret[$mac][$log_date]['REAL_DATE'] = strtotime(preg_replace("/[^0-9]*/","",$log_date)); if(isset($res['XML']['SHOW_LOG_FILES_BY_DATE_AND_MAC'])){ $ret[$mac][$log_date]['FILES'] = $res['XML']['SHOW_LOG_FILES_BY_DATE_AND_MAC']; diff --git a/trunk/gosa-plugins/goto/addons/goto/class_gotoLogView.inc b/trunk/gosa-plugins/goto/addons/goto/class_gotoLogView.inc index a5e166ff2..c8b9dd18d 100644 --- a/trunk/gosa-plugins/goto/addons/goto/class_gotoLogView.inc +++ b/trunk/gosa-plugins/goto/addons/goto/class_gotoLogView.inc @@ -13,6 +13,7 @@ class gotoLogView extends plugin var $selected_date; var $selected_file = 0; + var $selected_type; var $attributes = array("macAddress"); var $macAddress = ""; @@ -77,12 +78,16 @@ class gotoLogView extends plugin $smarty->assign("mac",$this->mac); $smarty->assign("selected_file",$this->selected_file); $smarty->assign("selected_date",$this->selected_date); - $smarty->assign("log_file", $this->get_log($this->mac,$this->selected_date,$this->selected_file)); + $smarty->assign("selected_type",$this->selected_type); + $smarty->assign("log_file", $this->get_log($this->mac,$this->selected_date,$this->selected_file, $this->selected_type)); $smarty->assign("standalone",$this->standalone); if (isset($this->logs[$this->mac])){ $date = date("d.m.Y H:i:s",$this->logs[$this->mac][$this->selected_date]['REAL_DATE']); } + if (isset($this->logs[$this->mac])){ + $type = $this->logs[$this->mac][$this->selected_date]['FAI_ACTION']; + } $file = $this->selected_file; $smarty->assign("selected_log",_("none")); if(!empty($file)){ @@ -98,22 +103,38 @@ class gotoLogView extends plugin }else{ $img = "/\\sort_by == "file"){ - $img1 = $img; - $img2 = ""; - }else{ - $img1 = ""; - $img2 = $img; - } + $file_img = ""; + $type_img = ""; + $date_img = ""; + switch($this->sort_by) { + case "file": + $file_img = $img; + $type_img = ""; + $date_img = ""; + break; + case "time": + $date_img = $img; + $type_img = ""; + $file_img = ""; + break; + case "type": + $type_img = $img; + $date_img = ""; + $file_img = ""; + break; + } /* Create list header */ $divlist->SetHeader(array( - array("string"=>""._("File")." ".$img1."", + array("string"=>""._("File")." ".$file_img."", "attach"=>"width='200px;'"), - array("string"=>""._("Date")." ".$img2."", + array("string"=>""._("Type")." ".$type_img."", + "attach" => "style='border-right:none;'"), + array("string"=>""._("Date")." ".$date_img."", "attach" => "style='border-right:none;'"), + )); /* Create divlist list @@ -123,16 +144,25 @@ class gotoLogView extends plugin /* Create sortable array */ - $link = "%str%"; + $link = "%str%"; $to_add = array(); $sort_by = $this->sort_by; foreach($this->logs as $mac => $times){ foreach($times as $time => $data){ $rtime = $data['REAL_DATE']; + $type = $data['FAI_ACTION']; + switch($type) { + case 'softupdate': + $type = _("Software update"); + break; + case 'install': + $type = _("Installation"); + break; + } foreach($data['FILES'] as $file){ $highlight = ""; - if($file == $this->selected_file && $time == $this->selected_date && $mac == $this->mac){ + if($file == $this->selected_file && $time == $this->selected_date && $mac == $this->mac && $type == $this->selected_type){ $highlight = "background-color:#CCCCCC"; } @@ -140,6 +170,8 @@ class gotoLogView extends plugin $to_add[$$sort_by.$file.$time] = array( array("string" => preg_replace("/%str%/",$file,$use_link), "attach" => "style='width:200px; $highlight'"), + array("string" => preg_replace("/%str%/",$type,$use_link), + "attach" => "style='width:200px; $highlight'"), array("string" => preg_replace("/%str%/",date("d.m.Y H:i:s",$rtime),$use_link), "attach" => "style='border-right:none; $highlight'"), ); @@ -168,9 +200,9 @@ class gotoLogView extends plugin } - function get_log($mac,$date,$file) + function get_log($mac,$date,$file,$type) { - $res = $this->o_queue->get_log_file($mac,$date,$file); + $res = $this->o_queue->get_log_file($mac,$date,$file, $type); if($this->o_queue->is_configured() && $this->o_queue->is_error()){ msg_dialog::display(_("Error"), $this->o_queue->get_error(), ERROR_DIALOG); } @@ -181,12 +213,12 @@ class gotoLogView extends plugin function save_object() { - foreach(array("time"=>"selected_date","file"=>"selected_file") as $attr => $dest){ + foreach(array("time"=>"selected_date","file"=>"selected_file","type"=>"selected_type") as $attr => $dest){ if(isset($_GET[$attr])){ $this->$dest = $_GET[$attr]; } } - if(isset($_GET['sort_by']) && in_array($_GET['sort_by'],array("file","time"))){ + if(isset($_GET['sort_by']) && in_array($_GET['sort_by'],array("file","time", "type"))){ if($_GET['sort_by'] == $this->sort_by){ $this->sort_dir = !$this->sort_dir; } 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 fa409588f..c0fbd8904 100644 --- a/trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po +++ b/trunk/gosa-plugins/goto/locale/de/LC_MESSAGES/messages.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: messages\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-11-03 14:33+0100\n" +"POT-Creation-Date: 2010-02-08 13:57+0100\n" "PO-Revision-Date: 2008-12-04 11:18+0100\n" "Last-Translator: Cajus Pollmeier \n" "Language-Team: deutsch \n" @@ -113,7 +113,7 @@ msgstr "Name" #: admin/systems/goto/ArpNewDevice.tpl:17 #: admin/systems/goto/class_workstationGeneric.inc:708 #: admin/systems/goto/workstation.tpl:19 admin/systems/goto/printer.tpl:16 -#: admin/systems/services/nfs/servnfs.tpl:19 +#: admin/systems/goto/printer.tpl:47 admin/systems/services/nfs/servnfs.tpl:19 #: admin/systems/services/nfs/class_servNfs.inc:216 #: admin/systems/services/shares/class_goShareServer.inc:424 #: admin/applications/generic.tpl:33 @@ -178,7 +178,7 @@ msgstr "Lieferanten-ID" #: addons/goto/class_gotomasses.inc:735 addons/goto/class_gotomasses.inc:739 #: addons/goto/class_gotomasses.inc:775 addons/goto/class_gotomasses.inc:819 #: addons/goto/class_target_list.inc:250 addons/goto/class_target_list.inc:254 -#: addons/goto/class_gotoLogView.inc:57 addons/goto/class_gotoLogView.inc:175 +#: addons/goto/class_gotoLogView.inc:58 addons/goto/class_gotoLogView.inc:208 msgid "Error" msgstr "Fehler" @@ -203,7 +203,7 @@ msgstr "Gerät" #: admin/systems/goto/class_printGeneric.inc:920 #: admin/systems/goto/class_terminalGeneric.inc:353 #: admin/systems/goto/class_terminalGeneric.inc:580 -#: admin/systems/goto/class_workstationService.inc:479 +#: admin/systems/goto/class_workstationService.inc:467 #: admin/systems/goto/class_workstationStartup.inc:893 #: admin/systems/goto/class_terminalService.inc:597 #: admin/systems/goto/class_ArpNewDevice.inc:69 @@ -280,6 +280,7 @@ msgstr "Basis" #: admin/systems/services/nfs/servnfs.tpl:56 #: admin/systems/services/nfs/class_servNfs.inc:202 #: admin/systems/services/shares/class_goShareServer.inc:425 +#: addons/goto/class_gotoLogView.inc:134 msgid "Type" msgstr "Typ" @@ -397,7 +398,7 @@ msgstr "Anlegen" #: admin/systems/goto/terminalStartup.tpl:115 #: admin/systems/goto/terminalService.tpl:212 #: admin/systems/goto/workstationStartup.tpl:233 -#: admin/systems/goto/printer.tpl:71 +#: admin/systems/goto/printer.tpl:82 #: admin/applications/class_applicationParameters.inc:122 #: admin/applications/class_divListApplication.inc:120 #: personal/environment/environment.tpl:238 @@ -727,7 +728,7 @@ msgid "Move down" msgstr "Nach unten bewegen" #: admin/groups/apps/app_list.tpl:88 admin/groups/apps/app_list.tpl:134 -#: admin/systems/goto/printer.tpl:68 +#: admin/systems/goto/printer.tpl:79 #: admin/systems/services/shares/goShareServer.tpl:17 #: personal/environment/environment.tpl:274 #: addons/goto/class_gotomasses.inc:469 @@ -1131,22 +1132,22 @@ msgstr "Andere Netzwerk-Komponente" #: admin/systems/goto/class_terminalGeneric.inc:137 #: admin/systems/goto/class_terminalGeneric.inc:287 #: admin/systems/goto/class_terminalGeneric.inc:299 +#: admin/systems/goto/class_workstationService.inc:206 +#: admin/systems/goto/class_workstationService.inc:210 +#: admin/systems/goto/class_workstationService.inc:213 +#: admin/systems/goto/class_workstationService.inc:216 #: admin/systems/goto/class_workstationService.inc:219 #: admin/systems/goto/class_workstationService.inc:222 #: admin/systems/goto/class_workstationService.inc:225 #: admin/systems/goto/class_workstationService.inc:228 -#: admin/systems/goto/class_workstationService.inc:231 -#: admin/systems/goto/class_workstationService.inc:234 -#: admin/systems/goto/class_workstationService.inc:237 +#: admin/systems/goto/class_workstationService.inc:239 #: admin/systems/goto/class_workstationService.inc:240 -#: admin/systems/goto/class_workstationService.inc:251 -#: admin/systems/goto/class_workstationService.inc:252 -#: admin/systems/goto/class_workstationService.inc:253 -#: admin/systems/goto/class_workstationService.inc:254 -#: admin/systems/goto/class_workstationService.inc:255 -#: admin/systems/goto/class_workstationService.inc:256 -#: admin/systems/goto/class_workstationService.inc:257 -#: admin/systems/goto/class_workstationService.inc:258 +#: admin/systems/goto/class_workstationService.inc:241 +#: admin/systems/goto/class_workstationService.inc:242 +#: admin/systems/goto/class_workstationService.inc:243 +#: admin/systems/goto/class_workstationService.inc:244 +#: admin/systems/goto/class_workstationService.inc:245 +#: admin/systems/goto/class_workstationService.inc:246 #: admin/systems/goto/class_workstationStartup.inc:178 #: admin/systems/goto/class_workstationStartup.inc:208 #: admin/systems/goto/class_terminalService.inc:182 @@ -1330,7 +1331,7 @@ msgid "Object is no printer!" msgstr "Das Objekt ist kein Drucker!" #: admin/systems/goto/class_printGeneric.inc:706 -#: admin/systems/goto/printer.tpl:54 +#: admin/systems/goto/printer.tpl:65 msgid "Printer URL" msgstr "Drucker URL" @@ -1372,7 +1373,7 @@ msgid "Printer PPD" msgstr "Drucker-PPD" #: admin/systems/goto/class_printGeneric.inc:970 -#: admin/systems/goto/printer.tpl:82 +#: admin/systems/goto/printer.tpl:93 msgid "Permissions" msgstr "Berechtigungen" @@ -1508,7 +1509,7 @@ msgstr "Wählen Sie den Maus-Port" #: admin/systems/goto/workstationService.tpl:86 #: admin/systems/goto/terminalService.tpl:76 -#: admin/systems/goto/class_workstationService.inc:538 +#: admin/systems/goto/class_workstationService.inc:526 #: admin/systems/goto/class_terminalService.inc:712 msgid "Telephone hardware" msgstr "Telefon-Hardware" @@ -1519,7 +1520,7 @@ msgid "Telephone" msgstr "Telefon" #: admin/systems/goto/workstationService.tpl:110 -#: admin/systems/goto/terminalService.tpl:98 admin/systems/goto/printer.tpl:66 +#: admin/systems/goto/terminalService.tpl:98 admin/systems/goto/printer.tpl:77 msgid "Driver" msgstr "Treiber" @@ -1557,7 +1558,7 @@ msgid "Display device" msgstr "Anzeige" #: admin/systems/goto/workstationService.tpl:157 -#: admin/systems/goto/class_workstationService.inc:106 +#: admin/systems/goto/class_workstationService.inc:91 #: admin/systems/goto/class_terminalService.inc:610 msgid "unknown" msgstr "unbekannt" @@ -1569,10 +1570,10 @@ msgstr "Verwende DDC zur automatischen Erkennung" #: admin/systems/goto/workstationService.tpl:170 #: admin/systems/goto/terminalService.tpl:150 -#: admin/systems/goto/class_workstationService.inc:425 -#: admin/systems/goto/class_workstationService.inc:427 -#: admin/systems/goto/class_workstationService.inc:432 -#: admin/systems/goto/class_workstationService.inc:529 +#: admin/systems/goto/class_workstationService.inc:413 +#: admin/systems/goto/class_workstationService.inc:415 +#: admin/systems/goto/class_workstationService.inc:420 +#: admin/systems/goto/class_workstationService.inc:517 #: admin/systems/goto/class_terminalService.inc:701 msgid "HSync" msgstr "HSync" @@ -1584,10 +1585,10 @@ msgstr "Horizontale Wiederholrate für den installierten Monitor" #: admin/systems/goto/workstationService.tpl:181 #: admin/systems/goto/terminalService.tpl:158 -#: admin/systems/goto/class_workstationService.inc:408 -#: admin/systems/goto/class_workstationService.inc:410 -#: admin/systems/goto/class_workstationService.inc:415 -#: admin/systems/goto/class_workstationService.inc:530 +#: admin/systems/goto/class_workstationService.inc:396 +#: admin/systems/goto/class_workstationService.inc:398 +#: admin/systems/goto/class_workstationService.inc:403 +#: admin/systems/goto/class_workstationService.inc:518 #: admin/systems/goto/class_terminalService.inc:702 msgid "VSync" msgstr "VSync" @@ -1631,7 +1632,7 @@ msgstr "Aktiv" #: admin/systems/goto/class_terminalGeneric.inc:187 #: admin/systems/goto/class_terminalGeneric.inc:594 -#: admin/systems/goto/class_workstationService.inc:586 +#: admin/systems/goto/class_workstationService.inc:574 #: admin/systems/goto/class_workstationStartup.inc:942 #: admin/systems/goto/class_workstationStartup.inc:1107 #: admin/systems/goto/class_workstationStartup.inc:1175 @@ -1774,7 +1775,7 @@ msgstr "Zugewiesene FAI-Klassen" msgid "set" msgstr "setzen" -#: admin/systems/goto/class_workstationService.inc:93 +#: admin/systems/goto/class_workstationService.inc:78 #: admin/systems/goto/class_workstationStartup.inc:1407 #: admin/systems/goto/class_workstationStartup.inc:1409 #: admin/systems/goto/class_terminalService.inc:121 @@ -1784,14 +1785,14 @@ msgstr "setzen" msgid "Configuration error" msgstr "Konfigurationsfehler" -#: admin/systems/goto/class_workstationService.inc:103 +#: admin/systems/goto/class_workstationService.inc:88 msgid "manual/auto" msgstr "manuell/auto" -#: admin/systems/goto/class_workstationService.inc:110 -#: admin/systems/goto/class_workstationService.inc:111 -#: admin/systems/goto/class_workstationService.inc:112 -#: admin/systems/goto/class_workstationService.inc:113 +#: admin/systems/goto/class_workstationService.inc:95 +#: admin/systems/goto/class_workstationService.inc:96 +#: admin/systems/goto/class_workstationService.inc:97 +#: admin/systems/goto/class_workstationService.inc:98 #: admin/systems/goto/class_terminalService.inc:128 #: admin/systems/goto/class_terminalService.inc:129 #: admin/systems/goto/class_terminalService.inc:130 @@ -1799,80 +1800,80 @@ msgstr "manuell/auto" msgid "bit" msgstr "Bit" -#: admin/systems/goto/class_workstationService.inc:172 +#: admin/systems/goto/class_workstationService.inc:157 #: admin/systems/goto/class_terminalService.inc:211 msgid "automatic" msgstr "automatisch" -#: admin/systems/goto/class_workstationService.inc:225 +#: admin/systems/goto/class_workstationService.inc:213 #: admin/systems/goto/class_terminalService.inc:274 msgid "Bit" msgstr "Bit" -#: admin/systems/goto/class_workstationService.inc:341 +#: admin/systems/goto/class_workstationService.inc:329 #: admin/systems/goto/class_terminalService.inc:421 msgid "Choose the phone located at the current terminal" msgstr "Wählen Sie das sich am momentanen Arbeitsplatz befindende Telefon." -#: admin/systems/goto/class_workstationService.inc:516 +#: admin/systems/goto/class_workstationService.inc:504 #: admin/systems/goto/class_terminalService.inc:685 msgid "Service" msgstr "Dienst" -#: admin/systems/goto/class_workstationService.inc:517 +#: admin/systems/goto/class_workstationService.inc:505 msgid "Workstation service" msgstr "Arbeitsstations-Dienst" -#: admin/systems/goto/class_workstationService.inc:525 +#: admin/systems/goto/class_workstationService.inc:513 #: admin/systems/goto/class_terminalService.inc:695 msgid "Monitor" msgstr "Monitor" -#: admin/systems/goto/class_workstationService.inc:526 +#: admin/systems/goto/class_workstationService.inc:514 #: admin/systems/goto/class_terminalService.inc:698 msgid "Gfx driver" msgstr "Grafiktreiber" -#: admin/systems/goto/class_workstationService.inc:527 +#: admin/systems/goto/class_workstationService.inc:515 #: admin/systems/goto/class_terminalService.inc:699 msgid "Gfx resolution" msgstr "Auflösung" -#: admin/systems/goto/class_workstationService.inc:528 +#: admin/systems/goto/class_workstationService.inc:516 #: admin/systems/goto/class_terminalService.inc:700 msgid "Gfx color depth" msgstr "Farbtiefe" -#: admin/systems/goto/class_workstationService.inc:531 +#: admin/systems/goto/class_workstationService.inc:519 msgid "Use DDC" msgstr "Verwende DDC" -#: admin/systems/goto/class_workstationService.inc:532 +#: admin/systems/goto/class_workstationService.inc:520 #: admin/systems/goto/class_terminalService.inc:704 msgid "Scanner enabled" msgstr "Scanner aktiviert" -#: admin/systems/goto/class_workstationService.inc:533 +#: admin/systems/goto/class_workstationService.inc:521 #: admin/systems/goto/class_terminalService.inc:706 msgid "Keyboard model" msgstr "Tastatur-Modell" -#: admin/systems/goto/class_workstationService.inc:534 +#: admin/systems/goto/class_workstationService.inc:522 #: admin/systems/goto/class_terminalService.inc:707 msgid "Keyboard layout" msgstr "Tastatur-Layout" -#: admin/systems/goto/class_workstationService.inc:535 +#: admin/systems/goto/class_workstationService.inc:523 #: admin/systems/goto/class_terminalService.inc:708 msgid "Keyboard variant" msgstr "Tastatur-Variante" -#: admin/systems/goto/class_workstationService.inc:536 +#: admin/systems/goto/class_workstationService.inc:524 #: admin/systems/goto/class_terminalService.inc:709 msgid "Mouse type" msgstr "Maus-Typ" -#: admin/systems/goto/class_workstationService.inc:537 +#: admin/systems/goto/class_workstationService.inc:525 #: admin/systems/goto/class_terminalService.inc:710 msgid "Mouse port" msgstr "Maus-Anschluß" @@ -2074,7 +2075,7 @@ msgid "Object group" msgstr "Objektgruppe" #: admin/systems/goto/SelectDeviceType.tpl:39 -#: addons/goto/class_gotoLogView.inc:87 +#: addons/goto/class_gotoLogView.inc:92 msgid "none" msgstr "keine" @@ -2177,6 +2178,7 @@ msgstr "Bits" #: admin/ogroups/goto/class_termgroup.inc:272 #: addons/goto/events/class_DaemonEvent_update.inc:29 #: addons/goto/events/class_DaemonEvent_update.inc:30 +#: addons/goto/class_gotoLogView.inc:157 msgid "Software update" msgstr "Softwareupdate" @@ -2282,31 +2284,31 @@ msgstr "Wählen Sie den Teilbaum, in den der Benutzer eingepflegt werden soll" msgid "Details" msgstr "Details" -#: admin/systems/goto/printer.tpl:46 +#: admin/systems/goto/printer.tpl:57 msgid "Printer location" msgstr "Drucker-Standort" -#: admin/systems/goto/printer.tpl:89 +#: admin/systems/goto/printer.tpl:100 msgid "Users which are allowed to use this printer" msgstr "Benutzer mit Berechtigung, diesen Drucker zu nutzen" -#: admin/systems/goto/printer.tpl:91 +#: admin/systems/goto/printer.tpl:102 msgid "Users" msgstr "Benutzer" -#: admin/systems/goto/printer.tpl:96 admin/systems/goto/printer.tpl:120 +#: admin/systems/goto/printer.tpl:107 admin/systems/goto/printer.tpl:131 msgid "Add user" msgstr "Benutzer hinzufügen" -#: admin/systems/goto/printer.tpl:99 admin/systems/goto/printer.tpl:123 +#: admin/systems/goto/printer.tpl:110 admin/systems/goto/printer.tpl:134 msgid "Add group" msgstr "Gruppe hinzufügen" -#: admin/systems/goto/printer.tpl:113 +#: admin/systems/goto/printer.tpl:124 msgid "Users which are allowed to administrate this printer" msgstr "Benutzer mit Berechtigung, diesen Drucker zu verwalten" -#: admin/systems/goto/printer.tpl:115 +#: admin/systems/goto/printer.tpl:126 msgid "Admins" msgstr "Administratoren" @@ -3942,19 +3944,23 @@ msgstr "IP" msgid "DHCP" msgstr "DHCP" -#: addons/goto/class_gotoLogView.inc:113 +#: addons/goto/class_gotoLogView.inc:132 msgid "File" msgstr "Datei" -#: addons/goto/class_gotoLogView.inc:115 +#: addons/goto/class_gotoLogView.inc:136 msgid "Date" msgstr "Datum" -#: addons/goto/class_gotoLogView.inc:202 +#: addons/goto/class_gotoLogView.inc:160 +msgid "Installation" +msgstr "Installation" + +#: addons/goto/class_gotoLogView.inc:235 msgid "Log view" msgstr "Log-Ansicht" -#: addons/goto/class_gotoLogView.inc:203 +#: addons/goto/class_gotoLogView.inc:236 msgid "GOto log view" msgstr "GOto Log-Ansicht" diff --git a/trunk/gosa-plugins/goto/locale/messages.po b/trunk/gosa-plugins/goto/locale/messages.po index b8ca931b3..47cb4ba5d 100644 --- a/trunk/gosa-plugins/goto/locale/messages.po +++ b/trunk/gosa-plugins/goto/locale/messages.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-11-03 14:33+0100\n" +"POT-Creation-Date: 2010-02-08 13:57+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -107,7 +107,7 @@ msgstr "" #: admin/systems/goto/ArpNewDevice.tpl:17 #: admin/systems/goto/class_workstationGeneric.inc:708 #: admin/systems/goto/workstation.tpl:19 admin/systems/goto/printer.tpl:16 -#: admin/systems/services/nfs/servnfs.tpl:19 +#: admin/systems/goto/printer.tpl:47 admin/systems/services/nfs/servnfs.tpl:19 #: admin/systems/services/nfs/class_servNfs.inc:216 #: admin/systems/services/shares/class_goShareServer.inc:424 #: admin/applications/generic.tpl:33 @@ -171,7 +171,7 @@ msgstr "" #: addons/goto/class_gotomasses.inc:735 addons/goto/class_gotomasses.inc:739 #: addons/goto/class_gotomasses.inc:775 addons/goto/class_gotomasses.inc:819 #: addons/goto/class_target_list.inc:250 addons/goto/class_target_list.inc:254 -#: addons/goto/class_gotoLogView.inc:57 addons/goto/class_gotoLogView.inc:175 +#: addons/goto/class_gotoLogView.inc:58 addons/goto/class_gotoLogView.inc:208 msgid "Error" msgstr "" @@ -196,7 +196,7 @@ msgstr "" #: admin/systems/goto/class_printGeneric.inc:920 #: admin/systems/goto/class_terminalGeneric.inc:353 #: admin/systems/goto/class_terminalGeneric.inc:580 -#: admin/systems/goto/class_workstationService.inc:479 +#: admin/systems/goto/class_workstationService.inc:467 #: admin/systems/goto/class_workstationStartup.inc:893 #: admin/systems/goto/class_terminalService.inc:597 #: admin/systems/goto/class_ArpNewDevice.inc:69 @@ -273,6 +273,7 @@ msgstr "" #: admin/systems/services/nfs/servnfs.tpl:56 #: admin/systems/services/nfs/class_servNfs.inc:202 #: admin/systems/services/shares/class_goShareServer.inc:425 +#: addons/goto/class_gotoLogView.inc:134 msgid "Type" msgstr "" @@ -390,7 +391,7 @@ msgstr "" #: admin/systems/goto/terminalStartup.tpl:115 #: admin/systems/goto/terminalService.tpl:212 #: admin/systems/goto/workstationStartup.tpl:233 -#: admin/systems/goto/printer.tpl:71 +#: admin/systems/goto/printer.tpl:82 #: admin/applications/class_applicationParameters.inc:122 #: admin/applications/class_divListApplication.inc:120 #: personal/environment/environment.tpl:238 @@ -712,7 +713,7 @@ msgid "Move down" msgstr "" #: admin/groups/apps/app_list.tpl:88 admin/groups/apps/app_list.tpl:134 -#: admin/systems/goto/printer.tpl:68 +#: admin/systems/goto/printer.tpl:79 #: admin/systems/services/shares/goShareServer.tpl:17 #: personal/environment/environment.tpl:274 #: addons/goto/class_gotomasses.inc:469 @@ -1105,22 +1106,22 @@ msgstr "" #: admin/systems/goto/class_terminalGeneric.inc:137 #: admin/systems/goto/class_terminalGeneric.inc:287 #: admin/systems/goto/class_terminalGeneric.inc:299 +#: admin/systems/goto/class_workstationService.inc:206 +#: admin/systems/goto/class_workstationService.inc:210 +#: admin/systems/goto/class_workstationService.inc:213 +#: admin/systems/goto/class_workstationService.inc:216 #: admin/systems/goto/class_workstationService.inc:219 #: admin/systems/goto/class_workstationService.inc:222 #: admin/systems/goto/class_workstationService.inc:225 #: admin/systems/goto/class_workstationService.inc:228 -#: admin/systems/goto/class_workstationService.inc:231 -#: admin/systems/goto/class_workstationService.inc:234 -#: admin/systems/goto/class_workstationService.inc:237 +#: admin/systems/goto/class_workstationService.inc:239 #: admin/systems/goto/class_workstationService.inc:240 -#: admin/systems/goto/class_workstationService.inc:251 -#: admin/systems/goto/class_workstationService.inc:252 -#: admin/systems/goto/class_workstationService.inc:253 -#: admin/systems/goto/class_workstationService.inc:254 -#: admin/systems/goto/class_workstationService.inc:255 -#: admin/systems/goto/class_workstationService.inc:256 -#: admin/systems/goto/class_workstationService.inc:257 -#: admin/systems/goto/class_workstationService.inc:258 +#: admin/systems/goto/class_workstationService.inc:241 +#: admin/systems/goto/class_workstationService.inc:242 +#: admin/systems/goto/class_workstationService.inc:243 +#: admin/systems/goto/class_workstationService.inc:244 +#: admin/systems/goto/class_workstationService.inc:245 +#: admin/systems/goto/class_workstationService.inc:246 #: admin/systems/goto/class_workstationStartup.inc:178 #: admin/systems/goto/class_workstationStartup.inc:208 #: admin/systems/goto/class_terminalService.inc:182 @@ -1292,7 +1293,7 @@ msgid "Object is no printer!" msgstr "" #: admin/systems/goto/class_printGeneric.inc:706 -#: admin/systems/goto/printer.tpl:54 +#: admin/systems/goto/printer.tpl:65 msgid "Printer URL" msgstr "" @@ -1334,7 +1335,7 @@ msgid "Printer PPD" msgstr "" #: admin/systems/goto/class_printGeneric.inc:970 -#: admin/systems/goto/printer.tpl:82 +#: admin/systems/goto/printer.tpl:93 msgid "Permissions" msgstr "" @@ -1467,7 +1468,7 @@ msgstr "" #: admin/systems/goto/workstationService.tpl:86 #: admin/systems/goto/terminalService.tpl:76 -#: admin/systems/goto/class_workstationService.inc:538 +#: admin/systems/goto/class_workstationService.inc:526 #: admin/systems/goto/class_terminalService.inc:712 msgid "Telephone hardware" msgstr "" @@ -1478,7 +1479,7 @@ msgid "Telephone" msgstr "" #: admin/systems/goto/workstationService.tpl:110 -#: admin/systems/goto/terminalService.tpl:98 admin/systems/goto/printer.tpl:66 +#: admin/systems/goto/terminalService.tpl:98 admin/systems/goto/printer.tpl:77 msgid "Driver" msgstr "" @@ -1515,7 +1516,7 @@ msgid "Display device" msgstr "" #: admin/systems/goto/workstationService.tpl:157 -#: admin/systems/goto/class_workstationService.inc:106 +#: admin/systems/goto/class_workstationService.inc:91 #: admin/systems/goto/class_terminalService.inc:610 msgid "unknown" msgstr "" @@ -1527,10 +1528,10 @@ msgstr "" #: admin/systems/goto/workstationService.tpl:170 #: admin/systems/goto/terminalService.tpl:150 -#: admin/systems/goto/class_workstationService.inc:425 -#: admin/systems/goto/class_workstationService.inc:427 -#: admin/systems/goto/class_workstationService.inc:432 -#: admin/systems/goto/class_workstationService.inc:529 +#: admin/systems/goto/class_workstationService.inc:413 +#: admin/systems/goto/class_workstationService.inc:415 +#: admin/systems/goto/class_workstationService.inc:420 +#: admin/systems/goto/class_workstationService.inc:517 #: admin/systems/goto/class_terminalService.inc:701 msgid "HSync" msgstr "" @@ -1542,10 +1543,10 @@ msgstr "" #: admin/systems/goto/workstationService.tpl:181 #: admin/systems/goto/terminalService.tpl:158 -#: admin/systems/goto/class_workstationService.inc:408 -#: admin/systems/goto/class_workstationService.inc:410 -#: admin/systems/goto/class_workstationService.inc:415 -#: admin/systems/goto/class_workstationService.inc:530 +#: admin/systems/goto/class_workstationService.inc:396 +#: admin/systems/goto/class_workstationService.inc:398 +#: admin/systems/goto/class_workstationService.inc:403 +#: admin/systems/goto/class_workstationService.inc:518 #: admin/systems/goto/class_terminalService.inc:702 msgid "VSync" msgstr "" @@ -1589,7 +1590,7 @@ msgstr "" #: admin/systems/goto/class_terminalGeneric.inc:187 #: admin/systems/goto/class_terminalGeneric.inc:594 -#: admin/systems/goto/class_workstationService.inc:586 +#: admin/systems/goto/class_workstationService.inc:574 #: admin/systems/goto/class_workstationStartup.inc:942 #: admin/systems/goto/class_workstationStartup.inc:1107 #: admin/systems/goto/class_workstationStartup.inc:1175 @@ -1730,7 +1731,7 @@ msgstr "" msgid "set" msgstr "" -#: admin/systems/goto/class_workstationService.inc:93 +#: admin/systems/goto/class_workstationService.inc:78 #: admin/systems/goto/class_workstationStartup.inc:1407 #: admin/systems/goto/class_workstationStartup.inc:1409 #: admin/systems/goto/class_terminalService.inc:121 @@ -1740,14 +1741,14 @@ msgstr "" msgid "Configuration error" msgstr "" -#: admin/systems/goto/class_workstationService.inc:103 +#: admin/systems/goto/class_workstationService.inc:88 msgid "manual/auto" msgstr "" -#: admin/systems/goto/class_workstationService.inc:110 -#: admin/systems/goto/class_workstationService.inc:111 -#: admin/systems/goto/class_workstationService.inc:112 -#: admin/systems/goto/class_workstationService.inc:113 +#: admin/systems/goto/class_workstationService.inc:95 +#: admin/systems/goto/class_workstationService.inc:96 +#: admin/systems/goto/class_workstationService.inc:97 +#: admin/systems/goto/class_workstationService.inc:98 #: admin/systems/goto/class_terminalService.inc:128 #: admin/systems/goto/class_terminalService.inc:129 #: admin/systems/goto/class_terminalService.inc:130 @@ -1755,80 +1756,80 @@ msgstr "" msgid "bit" msgstr "" -#: admin/systems/goto/class_workstationService.inc:172 +#: admin/systems/goto/class_workstationService.inc:157 #: admin/systems/goto/class_terminalService.inc:211 msgid "automatic" msgstr "" -#: admin/systems/goto/class_workstationService.inc:225 +#: admin/systems/goto/class_workstationService.inc:213 #: admin/systems/goto/class_terminalService.inc:274 msgid "Bit" msgstr "" -#: admin/systems/goto/class_workstationService.inc:341 +#: admin/systems/goto/class_workstationService.inc:329 #: admin/systems/goto/class_terminalService.inc:421 msgid "Choose the phone located at the current terminal" msgstr "" -#: admin/systems/goto/class_workstationService.inc:516 +#: admin/systems/goto/class_workstationService.inc:504 #: admin/systems/goto/class_terminalService.inc:685 msgid "Service" msgstr "" -#: admin/systems/goto/class_workstationService.inc:517 +#: admin/systems/goto/class_workstationService.inc:505 msgid "Workstation service" msgstr "" -#: admin/systems/goto/class_workstationService.inc:525 +#: admin/systems/goto/class_workstationService.inc:513 #: admin/systems/goto/class_terminalService.inc:695 msgid "Monitor" msgstr "" -#: admin/systems/goto/class_workstationService.inc:526 +#: admin/systems/goto/class_workstationService.inc:514 #: admin/systems/goto/class_terminalService.inc:698 msgid "Gfx driver" msgstr "" -#: admin/systems/goto/class_workstationService.inc:527 +#: admin/systems/goto/class_workstationService.inc:515 #: admin/systems/goto/class_terminalService.inc:699 msgid "Gfx resolution" msgstr "" -#: admin/systems/goto/class_workstationService.inc:528 +#: admin/systems/goto/class_workstationService.inc:516 #: admin/systems/goto/class_terminalService.inc:700 msgid "Gfx color depth" msgstr "" -#: admin/systems/goto/class_workstationService.inc:531 +#: admin/systems/goto/class_workstationService.inc:519 msgid "Use DDC" msgstr "" -#: admin/systems/goto/class_workstationService.inc:532 +#: admin/systems/goto/class_workstationService.inc:520 #: admin/systems/goto/class_terminalService.inc:704 msgid "Scanner enabled" msgstr "" -#: admin/systems/goto/class_workstationService.inc:533 +#: admin/systems/goto/class_workstationService.inc:521 #: admin/systems/goto/class_terminalService.inc:706 msgid "Keyboard model" msgstr "" -#: admin/systems/goto/class_workstationService.inc:534 +#: admin/systems/goto/class_workstationService.inc:522 #: admin/systems/goto/class_terminalService.inc:707 msgid "Keyboard layout" msgstr "" -#: admin/systems/goto/class_workstationService.inc:535 +#: admin/systems/goto/class_workstationService.inc:523 #: admin/systems/goto/class_terminalService.inc:708 msgid "Keyboard variant" msgstr "" -#: admin/systems/goto/class_workstationService.inc:536 +#: admin/systems/goto/class_workstationService.inc:524 #: admin/systems/goto/class_terminalService.inc:709 msgid "Mouse type" msgstr "" -#: admin/systems/goto/class_workstationService.inc:537 +#: admin/systems/goto/class_workstationService.inc:525 #: admin/systems/goto/class_terminalService.inc:710 msgid "Mouse port" msgstr "" @@ -2013,7 +2014,7 @@ msgid "Object group" msgstr "" #: admin/systems/goto/SelectDeviceType.tpl:39 -#: addons/goto/class_gotoLogView.inc:87 +#: addons/goto/class_gotoLogView.inc:92 msgid "none" msgstr "" @@ -2112,6 +2113,7 @@ msgstr "" #: admin/ogroups/goto/class_termgroup.inc:272 #: addons/goto/events/class_DaemonEvent_update.inc:29 #: addons/goto/events/class_DaemonEvent_update.inc:30 +#: addons/goto/class_gotoLogView.inc:157 msgid "Software update" msgstr "" @@ -2211,31 +2213,31 @@ msgstr "" msgid "Details" msgstr "" -#: admin/systems/goto/printer.tpl:46 +#: admin/systems/goto/printer.tpl:57 msgid "Printer location" msgstr "" -#: admin/systems/goto/printer.tpl:89 +#: admin/systems/goto/printer.tpl:100 msgid "Users which are allowed to use this printer" msgstr "" -#: admin/systems/goto/printer.tpl:91 +#: admin/systems/goto/printer.tpl:102 msgid "Users" msgstr "" -#: admin/systems/goto/printer.tpl:96 admin/systems/goto/printer.tpl:120 +#: admin/systems/goto/printer.tpl:107 admin/systems/goto/printer.tpl:131 msgid "Add user" msgstr "" -#: admin/systems/goto/printer.tpl:99 admin/systems/goto/printer.tpl:123 +#: admin/systems/goto/printer.tpl:110 admin/systems/goto/printer.tpl:134 msgid "Add group" msgstr "" -#: admin/systems/goto/printer.tpl:113 +#: admin/systems/goto/printer.tpl:124 msgid "Users which are allowed to administrate this printer" msgstr "" -#: admin/systems/goto/printer.tpl:115 +#: admin/systems/goto/printer.tpl:126 msgid "Admins" msgstr "" @@ -3827,19 +3829,23 @@ msgstr "" msgid "DHCP" msgstr "" -#: addons/goto/class_gotoLogView.inc:113 +#: addons/goto/class_gotoLogView.inc:132 msgid "File" msgstr "" -#: addons/goto/class_gotoLogView.inc:115 +#: addons/goto/class_gotoLogView.inc:136 msgid "Date" msgstr "" -#: addons/goto/class_gotoLogView.inc:202 +#: addons/goto/class_gotoLogView.inc:160 +msgid "Installation" +msgstr "" + +#: addons/goto/class_gotoLogView.inc:235 msgid "Log view" msgstr "" -#: addons/goto/class_gotoLogView.inc:203 +#: addons/goto/class_gotoLogView.inc:236 msgid "GOto log view" msgstr "" diff --git a/trunk/gosa-si/gosa-si-client b/trunk/gosa-si/gosa-si-client index 82112fb7c..45a3b2938 100755 --- a/trunk/gosa-si/gosa-si-client +++ b/trunk/gosa-si/gosa-si-client @@ -163,7 +163,6 @@ sub check_cmdline_param () { } } - #=== FUNCTION ================================================================ # NAME: check_pid # PARAMETERS: @@ -317,7 +316,6 @@ sub get_mac { } - #=== FUNCTION ================================================================ # NAME: get_local_mac_for_remote_ip # PARAMETERS: none (takes server_ip from global variable) @@ -898,7 +896,7 @@ sub fifo_got_record { &send_msg_to_target($clmsg, $server_address, $server_key, "CLMSG_$header"); # if installation finished, save all log files - if ($file_record eq "TASKBEGIN finish") { + if ($file_record eq "TASKBEGIN savelog") { &save_fai_log($fai_log_dir); } @@ -909,6 +907,7 @@ sub fifo_got_record { sub save_fai_log { my ($fai_log_dir) = @_ ; my $FAI_DIR; + my $fai_action; # Directory for log files after a softupdate my $log_dir = File::Spec->catdir($fai_log_dir, "localhost/last"); @@ -920,6 +919,11 @@ sub save_fai_log { daemon_log("ERROR: cannot open directory $log_dir", 1); return; } + $fai_action = "install"; + } + else { + # If we already have a logdir, we can assume that this is a softupdate + $fai_action = "softupdate"; } opendir($FAI_DIR, "$log_dir"); @@ -949,6 +953,7 @@ sub save_fai_log { my $all_log_string = join("\n", @log_list); my $msg_hash = &create_xml_hash("CLMSG_save_fai_log", $client_address, $server_address, $all_log_string); &add_content2xml_hash($msg_hash, "macaddress", $client_mac_address); + &add_content2xml_hash($msg_hash, "fai_action", $fai_action); my $msg = &create_xml_string($msg_hash); &send_msg_to_target($msg, $server_address, $server_key, "CLMSG_save_fai_log"); diff --git a/trunk/gosa-si/server/events/clMessages.pm b/trunk/gosa-si/server/events/clMessages.pm index b818b707f..7bad55ec1 100644 --- a/trunk/gosa-si/server/events/clMessages.pm +++ b/trunk/gosa-si/server/events/clMessages.pm @@ -72,6 +72,7 @@ sub save_fai_log { my $header = @{$msg_hash->{'header'}}[0]; my $source = @{$msg_hash->{'source'}}[0]; my $macaddress = @{$msg_hash->{'macaddress'}}[0]; + my $fai_action = @{$msg_hash->{'fai_action'}}[0]; my $all_logs = @{$msg_hash->{$header}}[0]; # if there is nothing to log @@ -92,7 +93,7 @@ sub save_fai_log { my $time = &get_time; $time = substr($time, 0, 8)."_".substr($time, 8, 6); - $client_fai_log_dir = File::Spec->catfile( $client_fai_log_dir, "install_$time" ); + $client_fai_log_dir = File::Spec->catfile( $client_fai_log_dir, $fai_action ."_".$time ); mkdir($client_fai_log_dir, 0755); my @all_logs = split(/log_file:/, $all_logs); -- 2.30.2