hi!
In the freemarker template, I want to get the path of noderef by using the following code.
<#if document?exists>
<table><tr><th>Node Path</th></tr>
<#list document.auditTrail as t>
<tr>
<#if t.auditMethod="moveNode">
<#if t.methodArgumentsAsStrings[0]?exists>
<#assign x=t.methodArgumentsAsStrings[0]>
td>${companyhome.nodeByReference[x].displayPath}</td>
<#else>
<td> </td>
</#if>
</#if>
</tr>
</#list>
</table>
</#if>
I get the following error:
'Expression companyhome.nodeByReference[x] is undefined on line 12, column 57 in workspace://SpacesStore/ba1b4ef2-a550-11db-b0b5-3b9e2324cece.'
How can i correct it? What is right way to access the path by using noderef in the freemarker template file?