[rt-users] Capturing 'Started' Value

john.white john.white at cardiocore.com
Tue Dec 9 08:34:13 EST 2014


This is for RT ver. 3.8.2.  I'm trying to capture the "Started" field value in the Dates block and place it in a Custom Field (called Started Date) so that I can output that data in the spread sheet reports to perform metrics (don't see how to output that data to the spreadsheets any other way).  I'm trying to grab it when a ticket first comes into our "General" queue and then keep it when I move that ticket into my AppSupport Queue.  I have the custom field set up but I can't seem to put the value in it properly, I keep getting some strange, I think hex, numerical value instead.  Not sure how to get it to work...  Here's what I have so far as a scrip on the General and AppSupport queues:

Condition: On Create
Action: User Defined
Template: Global Template Blank

Custom Condition:

Custom Action Preparation Code:
Return 1;

Custom Action Cleanup Code:
my $CFName = 'Started Date';
my $DefaultValue = RT::Date->new ( $RT::SystemUser );

$DefaultValue->Set( Format => 'ISO', Value => $self->TicketObj->Started );

unless( $self->TicketObj->FirstCustomFieldValue( $CFName ) eq $DefaultValue ) {
                my( $st, $msg ) = $self->TicketObj->AddCustomFieldValue(
                                        Field => $CFName,
                                        Value => $DefaultValue );
return 1;

Any advice or help would be much appreciated!


John White
Application Support Lead

+1.301.214.7600 main
+1.301.214.6362 direct
+1.301.214.7601 fax
+1.703.615.4986 cellular


This email, including any attachments and files transmitted with it, are for the sole use of the intended recipient(s) to whom this email is addressed, and may contain confidential and/or privileged information. Any unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please be advised that you have received this email in error, and please contact the sender by reply email and destroy all copies (including all electronic and hard copies) of the original message. Thank you.

View this message in context: http://requesttracker.8502.n7.nabble.com/Capturing-Started-Value-tp59144.html
Sent from the Request Tracker - User mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20141209/ede4a40f/attachment.htm>

More information about the rt-users mailing list