Change AutoResponse Global Template based on time of the day
rjandric
rjandric at yahoo.com
Mon Oct 20 10:15:32 EDT 2014
OK, I've been trying with the following condition:
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime();
if ($hour >=8 && $hour <=17) {
$self->SetTemplate("Autoreply");
} elsif ($hour < 8 && $hour > 17) {
$self->SetTemplate("AutoReply-AfterHrs");
}
return 1;
But regardless of the conditions in if/elif I get both replies, from
Autoreply and AutoReply-AfterHrs templates. The logis seems OK, but I can't
tell where am I making a mistake. I have included a couple of screenshot
<http://requesttracker.8502.n7.nabble.com/file/n58870/Screen_Shot_2014-10-20_at_10.png>
s for both scrips.
<http://requesttracker.8502.n7.nabble.com/file/n58870/Screen_Shot_2014-10-20_at_10.png>
--
View this message in context: http://requesttracker.8502.n7.nabble.com/Change-AutoResponse-Global-Template-based-on-time-of-the-day-tp58825p58870.html
Sent from the Request Tracker - User mailing list archive at Nabble.com.
More information about the rt-users
mailing list