[rt-users] RT_System opening tickets?

Bruce Campbell bruce_campbell at ripe.net
Tue Jan 22 11:05:51 EST 2002


On Tue, 22 Jan 2002, Rafael Corvalan wrote:

> Hello,
> Ye, I understand the purpose of your action (only reopening the ticket).
>
> I our RT installation, I haven't the scrip you suggested since I don't
> want every queue AdminCC be notified for every correspondance on every
> ticket... If someone goes on holidays, he must reassign all his tickets
> and receiving all the correspondance is not good for us. Suppose I
> receive a mail notifying me of a new mail on a ticket that I don't own.
> How can I say "OK, it Bob's ticket but he's on holiday, I take the
> correspondance?". Somewhat complex and I think a lot of correspondance
> would be lost...

> In my configuration I have:
>
> OnCreate NotifyAllWatchers...
> OnCorrespondance NotifyOwner...

Hrm.  This is really a local administration issue, specific to your way of
doing things (ie, its not a problem with RT itself, just how you've got it
set up).

At the moment, you are depending on some external action (reassiging the
Owner) when someone goes on holiday.  Fine, if it works, you're home-free.
If it doesn't (as these things normally don't ;) ), you're in a bit of a
bind.

Assuming that you have a reliable system of detecting whether someone is
on holidays, you could do something like (replacing NotifyOwner):

	OnCorrespond NotifyOwnerOrAllIfOnHols using template Correspondence

The intended behaviour is that if Correspondence comes in on a ticket
while the Owner is on holidays, *all* AdminCcs will get it, with the
assumption that one of these will Steal the Ticket away from the previous
Owner so your Customer keeps getting interaction.

( If they don't Steal it away, then everyone will keep on getting the
  Correspondence while the Owner is on holidays )

As for what NotifyOwnerOrAllIfOnHols does, I'd suggest copying Notify.pm,
putting the required code in SetReceipients(), and Bob's your Auntie's
Live-In Lover.

Code snippet for SetReceipients below, you have to write your own
IsOnHolidays() routine to put in the module.

Regards,

-- 
                             Bruce Campbell                            RIPE
                   Systems/Network Engineer                             NCC
                 www.ripe.net - PGP562C8B1B                      Operations

    if ( ($arg =~ /\bOwner\b/) &&
         ($self->TicketObj->OwnerObj->id != $RT::Nobody->id) ) {
        my @additionals = ();
        if( $self->IsOnHolidays( $self->TicketObj->OwnerObj->EmailAddress ) ){
	    # The owner is on holidays.  Notify everyone
	    push(@additionals, @{$self->TicketObj->AdminCc->Emails});
	    push(@additionals, @{$self->TicketObj->QueueObj->AdminCc->Emails});
	}
        # If we're not sending to Ccs or requestors,
        # then the Owner can be the To.
        if (@To) {
            push(@Bcc, $self->TicketObj->OwnerObj->EmailAddress);
	    push(@Bcc, @additionals) if( defined( @additionals ) );
        }
        else {
            push(@To, $self->TicketObj->OwnerObj->EmailAddress);
	    push(@To, @additionals) if( defined( @additionals ) );
        }








More information about the rt-users mailing list