Hi,
I’m trying to figure out a way to have a scrip act differently based on
whether a transaction was based on an incoming e-mail or something done
from the web interface. Is there a hook for this?
(Perhaps check $self->TicketObj->Transactions->First->Message->First
for existance of a header named `Received’ via GetHeader method?
Has anybody tried that before? something like what’s shown at
http://www.soundwave.net/~wmono/rt/ but doing it this way sounds
a bit like a hack to me.)
Thanks,
-- Niels.
if ($self->TransactionObj->CreatorObj->Name eq ‘RT_System’) {
# created by system
} else {
# created by web interface
}On Tue, Aug 10, 2004 at 03:37:26PM +0200, Niels Bakker wrote:
Hi,
I’m trying to figure out a way to have a scrip act differently based on
whether a transaction was based on an incoming e-mail or something done
from the web interface. Is there a hook for this?
(Perhaps check $self->TicketObj->Transactions->First->Message->First
for existance of a header named `Received’ via GetHeader method?
Has anybody tried that before? something like what’s shown at
http://www.soundwave.net/~wmono/rt/ but doing it this way sounds
a bit like a hack to me.)
Thanks,
– Niels.
–
The rt-users Archives
Be sure to check out the RT wiki at http://wiki.bestpractical.com
Hi,
if ($self->TransactionObj->CreatorObj->Name eq ‘RT_System’) {
# created by system
} else {
# created by web interface
}
Doesn’t work (on 3.0.11); incoming mails $self->…->Name gets set
to the username associated with the From: header in the mail.
-- Niels.
Niels Bakker wrote:
Hi,
if ($self->TransactionObj->CreatorObj->Name eq ‘RT_System’) {
created by system
} else {
created by web interface
}
Doesn’t work (on 3.0.11); incoming mails $self->…->Name gets set
to the username associated with the From: header in the mail.
Use next hack:
$self->TransactionObj->Attachments->First->GetHeader(‘Received’);
RT WebUI doesn’t add this field to attachment header.