2013-03-07 Miguel de Dios <miguel.dedios@artica.es>

* lib/PandoraFMS/Core.pm: added in the start or end of downtimes
	the event with the id_user.
	
	Fixes: #3607163




git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@7811 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
mdtrooper 2013-03-07 17:30:26 +00:00
parent ca9088eb88
commit b10ff795e4
2 changed files with 13 additions and 4 deletions

View File

@ -1,3 +1,10 @@
2013-03-07 Miguel de Dios <miguel.dedios@artica.es>
* lib/PandoraFMS/Core.pm: added in the start or end of downtimes
the event with the id_user.
Fixes: #3607163
2013-03-07 Miguel de Dios <miguel.dedios@artica.es>
* lib/PandoraFMS/WMIServer.pm: fixed when the wmi query have not a

View File

@ -1116,7 +1116,8 @@ sub pandora_planned_downtime_disabled_once_stop($$) {
SET executed = 0
WHERE id = ?', $downtime->{'id'});
pandora_event ($pa_config, 'Server ' . $pa_config->{'servername'} . ' stopped planned downtime: ' . $downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
pandora_event ($pa_config,
'(Created by ' . $downtime->{'id_user'} . ') Server ' . $pa_config->{'servername'} . ' stopped planned downtime: ' . $downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
pandora_planned_downtime_unset_disabled_elements($pa_config,
$dbh, $downtime);
@ -1159,8 +1160,9 @@ sub pandora_planned_downtime_disabled_once_start($$) {
db_do($dbh, 'UPDATE tplanned_downtime
SET executed = 1
WHERE id = ?', $downtime->{'id'});
pandora_event ($pa_config,
"Server ".$pa_config->{'servername'}." started planned downtime: ".$downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
"(Created by " . $downtime->{'id_user'} . ") Server ".$pa_config->{'servername'}." started planned downtime: ".$downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
pandora_planned_downtime_set_disabled_elements($pa_config,
$dbh, $downtime);
@ -1352,7 +1354,7 @@ sub pandora_planned_downtime_quiet_once_stop($$) {
SET executed = 0
WHERE id = ?', $downtime->{'id'});
pandora_event ($pa_config,
"Server ".$pa_config->{'servername'}." stopped planned downtime: ".$downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
"(Created by " . $downtime->{'id_user'} . ") Server ".$pa_config->{'servername'}." stopped planned downtime: ".$downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
pandora_planned_downtime_unset_quiet_elements($pa_config,
$dbh, $downtime->{'id'});
@ -1393,7 +1395,7 @@ sub pandora_planned_downtime_quiet_once_start($$) {
SET executed = 1
WHERE id = ?', $downtime->{'id'});
pandora_event ($pa_config,
"Server ".$pa_config->{'servername'}." started planned downtime: ".$downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
"(Created by " . $downtime->{'id_user'} . ") Server ".$pa_config->{'servername'}." started planned downtime: ".$downtime->{'name'}, 0, 0, 1, 0, 0, 'system', 0, $dbh);
pandora_planned_downtime_set_quiet_elements($pa_config,
$dbh, $downtime->{'id'});