Hi guys,
I try to send a mail after owner change to the new and the old owner,
but I stuck…
I try to do it with a template.
New owner = {$Ticket->OwnerObj->Name}
oldOwner ?
Any help is appreciated.
Cheers,
Bjï¿œrn
Hi guys,
I try to send a mail after owner change to the new and the old owner,
but I stuck…
I try to do it with a template.
New owner = {$Ticket->OwnerObj->Name}
oldOwner ?
Any help is appreciated.
Cheers,
Bjï¿œrn
oldOwner ?
I think you grab that from the TransactionObj->OldValue, and find the user object and its email address from there.
Sorry I cannot remember the exact syntax, I am no where near my RT.
Roy
Hi Roy,
I’m on 3.8.7
I’ve tried:
Last Owner: {$TransactionObj->OldValue}
and get:
RT: Template parsing error: Can’t call method “OldValue” on an undefined
value at template line 15. Stack: [template:15]
Last Owner: {$Transaction->OldValue} gives me the ID of the User but I
need the RealName and the emailaddress.
Cheers,
Bj�rnAm 24.02.11 16:08, schrieb Raed El-Hames:
oldOwner ?
I think you grab that from the TransactionObj->OldValue, and find the user object and its email address from there.
Sorry I cannot remember the exact syntax, I am no where near my RT.Roy
-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com [mailto:rt-users-
bounces@lists.bestpractical.com] On Behalf Of Bj�rn Schulz
Sent: 24 February 2011 14:51
To: rt-users@lists.bestpractical.com
Subject: [rt-users] owner change - old ownerHi guys,
I try to send a mail after owner change to the new and the old owner,
but I stuck…
I try to do it with a template.New owner = {$Ticket->OwnerObj->Name}
oldOwner ?Any help is appreciated.
Cheers,
Bj�rn
Last Owner: {$Transaction->OldValue} gives me the ID of the User but I need the RealName and the emailaddress.
Yes that’s right and that’s what I meant by " find the user object and its email address from there"
You can do something like :
$user_obj = RT::User->new(RT::SystemUser);
$user_obj->Load({$Transaction->OldValue) ;
$user_email = $userObj->EmailAddress ;
Etc etc
Roy
That works fine thank you!
bjoernAm 24.02.11 17:15, schrieb Raed El-Hames:
Last Owner: {$Transaction->OldValue} gives me the ID of the User but I need the RealName and the emailaddress.
Yes that’s right and that’s what I meant by " find the user object and its email address from there"
You can do something like :$user_obj = RT::User->new(RT::SystemUser);
$user_obj->Load({$Transaction->OldValue) ;
$user_email = $userObj->EmailAddress ;Etc etc
Roy
-----Original Message-----
From: Bj�rn Schulz [mailto:bjoern.schulz@desy.de]
Sent: 24 February 2011 15:33
To: Raed El-Hames
Cc: rt-users@lists.bestpractical.com
Subject: Re: [rt-users] owner change - old ownerHi Roy,
I’m on 3.8.7I’ve tried:
Last Owner: {$TransactionObj->OldValue}and get:
RT: Template parsing error: Can’t call method “OldValue” on an undefined
value at template line 15. Stack: [template:15]Last Owner: {$Transaction->OldValue} gives me the ID of the User but I
need the RealName and the emailaddress.Cheers,
Bj�rnAm 24.02.11 16:08, schrieb Raed El-Hames:
oldOwner ?
I think you grab that from the TransactionObj->OldValue, and find the
user object and its email address from there.
Sorry I cannot remember the exact syntax, I am no where near my RT.Roy
-----Original Message-----
From: rt-users-bounces@lists.bestpractical.com [mailto:rt-users-
bounces@lists.bestpractical.com] On Behalf Of Bj�rn Schulz
Sent: 24 February 2011 14:51
To: rt-users@lists.bestpractical.com
Subject: [rt-users] owner change - old ownerHi guys,
I try to send a mail after owner change to the new and the old owner,
but I stuck…
I try to do it with a template.New owner = {$Ticket->OwnerObj->Name}
oldOwner ?Any help is appreciated.
Cheers,
Bj�rn