AnsweredAssumed Answered

Mail notification with content Info

Question asked by rockycres on Mar 20, 2009
Latest reply on Jul 29, 2010 by pp20218
Hi,

In my process definition.xml,I have a script which will send mail notification with content name and other info .

           <script>
                 var mail = actions.create("mail");
                 mail.parameters.to = 'santhosh.sekar@gmail.com';
                 mail.parameters.subject = "HI";
                 mail.parameters.from = 'santhosh.sekar@yahoo.com';                 
                 mail.parameters.template = companyhome.childByNamePath("Data Dictionary/Email Templates/new.ftl");             
                 mail.parameters.text = "It's done end ";
                 mail.execute(bpm_package);     
           </script>

In the template,

    <h4>Current Document Info:</h4>
   <b>Name:</b> ${document.name}<br>
   <b>Ref:</b> ${document.nodeRef}<br>
   <b>Type:</b> ${document.type}<br>
   <b>DBID:</b> ${document.properties["sys:node-dbid"]}<br>

But this is not fetching the right results.

This is the output I am getting…

Current Document Info:
Name: www
Ref   : avm://www–workflow-2fa1924f-82a1-4b0d-b110-0e4f159d3e9a/-1;www
Type :{http://www.alfresco.org/model/wcmmodel/1.0}avmlayeredfolder
DBID:2,373

How do I fetch the correct name of the files which were created as a part of the current workflow…Any help is appreciated…

Outcomes