<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic NPException generated  when accessing  Context on ftl freemarker in Nuxeo Forum</title>
    <link>https://connect.hyland.com/t5/nuxeo-forum/npexception-generated-when-accessing-context-on-ftl-freemarker/m-p/321599#M8600</link>
    <description>&lt;P&gt;Hi.
I have created a document template using freemarker.
How can i get the properties of parent of the current doc.
I can use the session to get what i want, but the context doesn`t work properly, it causes error.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;
&amp;lt;center&amp;gt;
&amp;lt;img src=${Env['nuxeo.url']}/img/stema_republikes.jpg" height="7%" width="5%"/&amp;gt;
&amp;lt;p style="font-weight:bold;font-size: 12pt;font-family: "Times New Roman", Times, serif;"&amp;gt;REPUBLIKA E SHQIPËRISË&amp;lt;/br&amp;gt;MINISTRIA E DREJTËSISË&amp;lt;/br&amp;gt;Drejtoria e Përgjithshme e Burgjeve&amp;lt;/p&amp;gt;
&amp;lt;/center&amp;gt;
&amp;lt;hr style="height:20px; color:black"/&amp;gt;
    &amp;lt;p style="float: right; width: 50%; text-align: right;font-size: 12pt;font-family: "Times New Roman", Times, serif;"&amp;gt;Afati i Ruajtjes __ vit&amp;lt;/br&amp;gt;Kopje nr. ___&amp;lt;/p&amp;gt;
&amp;lt;/br&amp;gt;&amp;lt;/br&amp;gt;
&amp;lt;center&amp;gt;
&amp;lt;p&amp;gt;&amp;lt;span  style="font-weight:bold;font-family: "Times New Roman", Times, serif;"&amp;gt;URDHËR TRANSFERIMI&amp;lt;/span&amp;gt;
&amp;lt;/br&amp;gt;Nr.__________ Datë ${CurrentDate.format("dd.MM.yyyy")}&amp;lt;/p&amp;gt;
&amp;lt;/center&amp;gt;

&amp;lt;p&amp;gt; ${Document["vendime:numer"]}&amp;lt;/br&amp;gt;
${Document.id}&amp;lt;/br&amp;gt;
${doc['vendime:numer']}&amp;lt;/br&amp;gt;
${session.getRepositoryName()}&amp;lt;/br&amp;gt;
${context.getClass()}&amp;lt;/br&amp;gt;
&amp;lt;/p&amp;gt;........etc
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 15 Nov 2016 16:17:35 GMT</pubDate>
    <dc:creator>Bora_</dc:creator>
    <dc:date>2016-11-15T16:17:35Z</dc:date>
    <item>
      <title>NPException generated  when accessing  Context on ftl freemarker</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/npexception-generated-when-accessing-context-on-ftl-freemarker/m-p/321599#M8600</link>
      <description>&lt;P&gt;Hi.
I have created a document template using freemarker.
How can i get the properties of parent of the current doc.
I can use the session to get what i want, but the context doesn`t work properly, it causes error.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;
&amp;lt;center&amp;gt;
&amp;lt;img src=${Env['nuxeo.url']}/img/stema_republikes.jpg" height="7%" width="5%"/&amp;gt;
&amp;lt;p style="font-weight:bold;font-size: 12pt;font-family: "Times New Roman", Times, serif;"&amp;gt;REPUBLIKA E SHQIPËRISË&amp;lt;/br&amp;gt;MINISTRIA E DREJTËSISË&amp;lt;/br&amp;gt;Drejtoria e Përgjithshme e Burgjeve&amp;lt;/p&amp;gt;
&amp;lt;/center&amp;gt;
&amp;lt;hr style="height:20px; color:black"/&amp;gt;
    &amp;lt;p style="float: right; width: 50%; text-align: right;font-size: 12pt;font-family: "Times New Roman", Times, serif;"&amp;gt;Afati i Ruajtjes __ vit&amp;lt;/br&amp;gt;Kopje nr. ___&amp;lt;/p&amp;gt;
&amp;lt;/br&amp;gt;&amp;lt;/br&amp;gt;
&amp;lt;center&amp;gt;
&amp;lt;p&amp;gt;&amp;lt;span  style="font-weight:bold;font-family: "Times New Roman", Times, serif;"&amp;gt;URDHËR TRANSFERIMI&amp;lt;/span&amp;gt;
&amp;lt;/br&amp;gt;Nr.__________ Datë ${CurrentDate.format("dd.MM.yyyy")}&amp;lt;/p&amp;gt;
&amp;lt;/center&amp;gt;

&amp;lt;p&amp;gt; ${Document["vendime:numer"]}&amp;lt;/br&amp;gt;
${Document.id}&amp;lt;/br&amp;gt;
${doc['vendime:numer']}&amp;lt;/br&amp;gt;
${session.getRepositoryName()}&amp;lt;/br&amp;gt;
${context.getClass()}&amp;lt;/br&amp;gt;
&amp;lt;/p&amp;gt;........etc
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 15 Nov 2016 16:17:35 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/npexception-generated-when-accessing-context-on-ftl-freemarker/m-p/321599#M8600</guid>
      <dc:creator>Bora_</dc:creator>
      <dc:date>2016-11-15T16:17:35Z</dc:date>
    </item>
    <item>
      <title>Re: NPException generated  when accessing  Context on ftl freemarker</title>
      <link>https://connect.hyland.com/t5/nuxeo-forum/npexception-generated-when-accessing-context-on-ftl-freemarker/m-p/321600#M8601</link>
      <description>&lt;P&gt;${Context['param_name']}&lt;/P&gt;</description>
      <pubDate>Wed, 16 Nov 2016 07:41:38 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/nuxeo-forum/npexception-generated-when-accessing-context-on-ftl-freemarker/m-p/321600#M8601</guid>
      <dc:creator>Bora_</dc:creator>
      <dc:date>2016-11-16T07:41:38Z</dc:date>
    </item>
  </channel>
</rss>

