[rt-users] Accessing Transactional Custom Fields From a Scrip

Christopher Snell chris.snell at gmail.com
Wed Aug 10 03:33:38 EDT 2005


On 8/10/05, Anders Ekstrand <anders.ekstrand at drutt.com> wrote:

> I have never got this to work, unfortunately...
>
> I ended up with the following scrip, that does not pick up any values:
>
> my $Transaction = $self->TransactionObj;
> my $CustomFieldValues=$Transaction->CustomFieldValues( "Internal status"

Bummer.  The whole system of accessing Custom Fields from scripts
seems so obtuse to me.  Why must we call all these methods to get at
the values?  I think it would be nicer from a programming standpoint
to be able to do things like this:

while my $a_custom_field (keys %{$self->TransactionObj->CustomFields}) {
    print "$a_custom_field  -->
$self->TransactionObj->CustomFields->{$a_custom_field} \n";
}

Perhaps these data structures are already in place and I just don't
know how to access them?  Can somebody enlighten me?

thx,

Chris



More information about the rt-users mailing list