[rt-users] custom Scrip...

Ayan R. Kayal ayan.kayal at yale.edu
Wed Aug 15 17:23:53 EDT 2001


I was trying to create a scrip that would be used for autoreplying, but only
if the requestor created the ticket. For example, if joe at my.domain creates a
ticket with bob at my.domain as the requestor (via the Web interface), it
shouldn't autoreply, but if joe at my.domain creates a ticket with himself as
the requestor, it will. And if joe at my.domain submits a ticket via email, it
should autoreply. I wrote the "if" statement below, but it's not right. I
suspect that the "$session{CurrentUser}->EmailAddress" part isn't right, but
I suspect something else is wrong too.


if (($self->TransactionObj->Field eq 'Requestors') and
    ($session{CurrentUser}->EmailAddress =~
/$self->TransactionObj->NewValue())/) {
        return(1);
    }
    else {
        return(undef);
    }

O-                         ~ARK





More information about the rt-users mailing list