<div dir="ltr">We classify tickets based on content and store that classification as a string in a CF called CF.{Classification}.  This is an RTIR instance but that is not really relevant other to say that when we open an Investigation on an Incident we want the template that is used for the Investigation to be dynamic based on the value of the CF.{Classification} field.<div>

<br></div><div>Currently what I'm doing is I have a Scrip for each Classification with a condition for that classification as well as the "On Create" condition.  When each Scrip fires it checks to see if the Investigation is that Classification.  If it is the template associated with the Scrip is used.  This is messy because it requires a Scrip for each Classification.</div>

<div><div><br></div><div style>Instead one Scrip for "On Create" that chooses the template dynamically.</div><div style><br></div><div style>What I think I can do is simply have one very short Template that is basically 100% perl and includes some text from a text file stored on the file system but outside RTIR.  Which file gets included in the Template is dependent upon the CF.{Classification}.</div>

<div style><br></div><div style>ie:</div><div style>{ require "/path/to/templates/".$Ticket->FirstCustomFieldValue('Classification').".template"; }</div><div><br></div><div style>Would this even work?  Is there a better way to choose a Perl template in the Scrip so that templates can be kept within RT?</div>

<div style><br></div>-- <br><div dir="ltr"><div><span style="font-family:arial;font-size:small">Landon Stewart :: </span><a href="mailto:lstewart@iweb.com" style="font-family:arial;font-size:small" target="_blank">lstewart@iweb.com</a><br>

</div><span style="font-family:arial;font-size:small">Lead Specialist, Abuse and Security Management</span><br style="font-family:arial;font-size:small"><span style="font-family:arial;font-size:small">Spécialiste principal, gestion des abus et sécurité</span><br style="font-family:arial;font-size:small">

<span style="font-family:arial;font-size:small"><a href="http://iweb.com" target="_blank">http://iweb.com</a> :: +1 (888) 909-4932</span><br><div><span style="font-family:arial;font-size:small"><br></span></div><div><span style="font-family:arial;font-size:small"><br>

</span></div></div>
</div></div>