2007-08-06 Sancho Lerena <slerena@gmail.com>
* DB.pm: Alert time support uses TIME format instead numeric (changes requested by esanchezm). git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@592 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
3a8d97d7a7
commit
a82dd59eb3
|
@ -1,3 +1,8 @@
|
|||
2007-08-06 Sancho Lerena <slerena@gmail.com>
|
||||
|
||||
* DB.pm: Alert time support uses TIME format instead numeric (changes requested
|
||||
by esanchezm).
|
||||
|
||||
2007-08-02 Sancho Lerena <slerena@gmail.com>
|
||||
|
||||
* Makefile.PL: Missing dep updated and .pl extensions purged.
|
||||
|
|
|
@ -137,10 +137,10 @@ sub pandora_calcula_alerta (%$$$$$$) {
|
|||
my $alert_timeto = $data[19];
|
||||
my $ahora_hour = &UnixDate("today","%H");
|
||||
my $ahora_min = &UnixDate("today","%M");
|
||||
my $ahora_time = $ahora_hour.":".$ahora_min;
|
||||
|
||||
# time check !
|
||||
if ( (((($ahora_hour * 60)+$ahora_min) >= ($alert_timefrom * 30)) &&
|
||||
((($ahora_hour * 60)+$ahora_min) <= ($alert_timeto * 30))) || ($alert_timefrom == $alert_timeto)) {
|
||||
if ((($ahora_time le $alert_timeto) && ($ahora_time ge $alert_timefrom)) || ($alert_timefrom eq $alert_timeto)){
|
||||
my $comando ="";
|
||||
logger($pa_config, "Found an alert defined for $nombre_modulo, its ID $id_alerta",4);
|
||||
# Here we process alert if conditions are ok
|
||||
|
|
Loading…
Reference in New Issue