[rt-users] How to get TicketObj from a Ticket ID
Jason A. Smith
smithj4 at bnl.gov
Tue Nov 17 09:42:53 EST 2009
On Tue, 2009-11-17 at 15:33 +0100, Brumm, Torsten / Kuehne + Nagel / Ham
MI-ID wrote:
> Hi,
> i'm now searching since some hours how to get the TicketObj from a given Ticket ID.
>
> Normally from within a scrip i go this way: $self->TicketObj and i can work with all the Information (like $self->TicketObj->Status etc)
>
> Now i have only i Ticket ID stored in a variable and i'm searching a way to get back my TicketObj.
>
> Any hints? I'm lost at the moment
Try something like:
my $Ticket = RT::Ticket->new($RT::SystemUser);
$Ticket->Load(TicketID#)
You can replace $RT::SystemUser with an RT::CurrentUser object for a
user in your system if you want to have actions restricted by or
transactions recorded for that user.
> Thanks
>
> Torsten
>
> Kuehne + Nagel (AG & Co.) KG, Geschaeftsleitung: Hans-Georg Brinkmann (Vors.), Dirk Blesius (Stellv.), Reiner Heiken (Stellv.), Bruno Mang, Alfred Manke, Christian Marnetté (Stellv.), Mark Reinhardt (Stellv.), Jens Wollesen, Rainer Wunn, Sitz: Bremen, Registergericht: Bremen, HRA 21928, USt-IdNr.: DE 812773878, Persoenlich haftende Gesellschaft: Kuehne & Nagel A.G., Sitz: Contern/Luxemburg Geschaeftsfuehrender Verwaltungsrat: Klaus-Michael Kuehne
>
>
>
> _______________________________________________
> http://lists.bestpractical.com/cgi-bin/mailman/listinfo/rt-users
>
> Community help: http://wiki.bestpractical.com
> Commercial support: sales at bestpractical.com
>
>
> Discover RT's hidden secrets with RT Essentials from O'Reilly Media.
> Buy a copy at http://rtbook.bestpractical.com
>
--
/------------------------------------------------------------------\
| Jason A. Smith Email: smithj4 at bnl.gov |
| Atlas Computing Facility, Bldg. 510M Phone: +1-631-344-4226 |
| Brookhaven National Lab, P.O. Box 5000 Fax: +1-631-344-7616 |
| Upton, NY 11973-5000, U.S.A. |
\------------------------------------------------------------------/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3906 bytes
Desc: not available
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20091117/7ce935de/attachment.bin>
More information about the rt-users
mailing list