Hi Joe,

This is a guess - as we don't make use of creating child tickets with
templates.

Replace the line, "ITNM-Topic:
{$Tickets{'TOP'}->CustomFieldValuesAsString('ITNM-Topic’)}" with the
following:

{
 my $cf = $Tickets{TOP}->LoadCustomFieldByIdentifier('ITNM-Topic');
 my $topics = $cf->ValuesForObject($Tickets{TOP})->ItemsArrayRef;

 join "\n",
     map { "ITNM-Topic: " . $_->Content }
     @$topics
 ;
}

The idea here is to insert into the template a line of:

ITNM-Topic: [blah]

for each value in your CF.

Alternatively to test things out, use the original line and an additional
line to see if you can pass multiple values to a child ticket's CF:

ITNM-Topic: {$Tickets{'TOP'}->FirstCustomFieldValue('ITNM-Topic’)}
ITNM-Topic: testing_multiple_values

Hopefully that child ticket will have two values in its ITNM-Topic CF.

Hope that helps!

-m


On Wed, Dec 2, 2015 at 9:56 AM, Joe Kirby <[email protected]> wrote:

> Thanks Matt
>
> When I do this ITNM-Topic:
> {$Tickets{'TOP'}->CustomFieldValuesAsString('ITNM-Topic’)} I still just get
> the first 1 in the list for the child ticket. It show fine in the parent
> ticket of course but is not transferring down to the child.
>
> I am on 4.2.11
>
> I appreciate your quick responses and ideas
>
> I included a snapshot of the parent and child in case that helped.
>
>
> Joe
>
> Joe Kirby ,  Assistant Vice President, Business Systems
> Division of Information Technology (DoIT)
> Support Response -   http://www.umbc.edu/doit
> Administration 627
> Office - 410-455-3020
> Email - [email protected]
>
> On Dec 2, 2015, at 10:38 AM, Matt Zagrabelny <[email protected]> wrote:
>
> On Wed, Dec 2, 2015 at 9:35 AM, Joe Kirby <[email protected]> wrote:
>
> Matt
>
> I appreciate the suggestion however as a non-perl programmer I am not able
> to transition this to my template
>
>
> Sure.
>
> I was hoping to have some command that would replace this line in the
> template so the child ticket could receive all the values from the parent
> as
> I am creating this dynamical via script/template
>
> ITNM-Topic: {$Tickets{'TOP'}->FirstCustomFieldValue('ITNM-Topic’)}
>
>
> Just replace the "FirstCustomFieldValue" with "CustomFieldValuesAsString".
>
> -m
>
>
>

Reply via email to