Skip to content

Commit

Permalink
fixed display when either grass or shrubs are being watered
Browse files Browse the repository at this point in the history
  • Loading branch information
hplato committed Aug 25, 2018
1 parent 672f17b commit 3c3058f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions code/common/calc_eto.pl
Original file line number Diff line number Diff line change
Expand Up @@ -956,15 +956,14 @@ sub detailSchedule {
my $station_id = 1;
$time = $time * 60; #add in seconds
foreach my $station (split /,/, $lengths) {
next if ($station == 0);
my $run_hour = 0;
if ($station > 3600) {
$run_hour = int($station / 3600);
$station = int($station % 3600);
}
my $run_min = int($station / 60);
my $run_sec = int($station % 60);
$msg .= "[calc_eto] : " . formatTime($time) . " : Station:" .sprintf("%2s",$station_id) . " Run Time:" .sprintf("%02d:%02d:%02d",$run_hour,$run_min,$run_sec) . "\n";
$msg .= "[calc_eto] : " . formatTime($time) . " : Station:" .sprintf("%2s",$station_id) . " Run Time:" .sprintf("%02d:%02d:%02d",$run_hour,$run_min,$run_sec) . "\n" unless ($station == 0);
$station_id++;
$time += $run_sec + ($run_min * 60) + ($run_hour * 3600);
}
Expand Down

0 comments on commit 3c3058f

Please sign in to comment.