apply a template from a workflow activity

smithcorey
Giga Contributor

Hi all,

So, I am trying to apply a template from a workflow activity.

I tried this in the workflow activity, but to no avail, so any input or direction would be most appreciated.

task.applyTemplate('u_template__1'); //u_template__1 is the name of the template I am trying to apply
1 ACCEPTED SOLUTION

Hi Michael,



Template(s) being applied is from one of 5 template variables (each a


separate reference field to sys_template table, on the sc_cat_item table.)


The workflow iterates through each of the templates,if not empty, applies


the template.



This is what ended up working in the script area of the Catalog Task


activity



task.applyTemplate(current.cat_item.*name of the template variable goes


here*.name +'');








On Wed, Apr 1, 2015 at 11:08 AM, Michael Ritchie <


View solution in original post

5 REPLIES 5

Hi Michael,



Template(s) being applied is from one of 5 template variables (each a


separate reference field to sys_template table, on the sc_cat_item table.)


The workflow iterates through each of the templates,if not empty, applies


the template.



This is what ended up working in the script area of the Catalog Task


activity



task.applyTemplate(current.cat_item.*name of the template variable goes


here*.name +'');








On Wed, Apr 1, 2015 at 11:08 AM, Michael Ritchie <