[rt-users] Reminders still open after a ticket is closed
Jim Tambling
Jim.Tambling at datatote.co.uk
Wed Feb 11 17:36:10 EST 2009
Thanks Mark
I tried that but it doesn't seem to work. Here's the code I put in the
scrip;
my $tickets = new RT::Tickets(RT->SystemUser)
my $id = $self->TicketObj->id;
my $queue = $self->TicketObj->QueueObj->Name;
return 1 unless (defined($id)); # Can this be undefined?
$tickets->FromSQL('Type = "reminder" AND RefersTo="'.$id.'"');
while (my $ticket = $tickets->Next) {
$RT::Logger->info("Closing associated reminder");
$ticket->SetStatus("resolved");
}
return 1;
I have zero knowledge of perl so I don't know if this is correct.
Regards
-----Original Message-----
From: Roedel, Mark [mailto:MarkRoedel at letu.edu]
Sent: 10 February 2009 23:04
To: Jim Tambling; rt-users at bestpractical.com
Subject: RE: [rt-users] Reminders still open after a ticket is closed
Looks to me like
http://wiki.bestpractical.com/view/OnQueueChangeFixReminders
<http://wiki.bestpractical.com/view/OnQueueChangeFixReminders> should
get you most of the way there as a jumping-off point. Obviously, you'd
change the scrip condition to "On Resolve" and you'd use a
$ticket->SetStatus('resolved') call in place of the
$Ticket->SetQueue($queue) in the while loop...
--
Mark Roedel
Senior Programmer/Analyst - Web Services
LeTourneau University
From: rt-users-bounces at lists.bestpractical.com
[mailto:rt-users-bounces at lists.bestpractical.com] On Behalf Of Jim
Tambling
Sent: Tuesday, February 10, 2009 4:37 PM
To: rt-users at bestpractical.com
Subject: [rt-users] Reminders still open after a ticket is closed
If I set a reminder for a ticket, after the ticket is resolved the
reminder is still active. Is there anyway to automate closing the
reminders on resolution of the ticket?
Regards
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20090211/472df087/attachment.htm>
More information about the rt-users
mailing list