[Rt-devel] determining the current value of a CustomField
Jens Porup
Jens.Porup at strategicdata.com.au
Wed Dec 21 01:07:32 EST 2005
OK.
I'm trying to determine the current value of a custom field.
I've tried this way:
# already have $Ticket object in <%args>
my $ObjectCustomFieldValues = $Ticket->CustomFieldValues("PO Status");
#$ObjectCustomFieldValues->LimitToObject($Ticket);
my $value = $ObjectCustomFieldValues->???????????
and a different tack:
# already have $Ticket object in <%args>
my $QueueObj = $Ticket->QueueObj();
my $CustomField = $QueueObj->CustomField("PO Status");
my $ObjectCustomFieldValues = $CustomField->ValuesForObject($Ticket);
my $value = $ObjectCustomFieldValues->???????????
At this point I'm stuck. I have the ObjectCustomFieldValues (plural) object.
But I need the singular ObjectCustomFieldValue object so I can call
->CustomField and get the current value.
I suppose, more generally, how in RT do I go from a plural object to a singular
object? I'm all out of ideas.
Thanks very much.
Jens
More information about the Rt-devel
mailing list