07-04-2014 01:02 PM
Hi,
I'm trying to attach the files form a document to an email notification, like this:
<chain id="envoyerMail">
<operation id="Context.FetchDocument" />
<operation id="Notification.SendMail">
<param type="string" name="from">expr:@{WorkflowVariables["expediteur"]}</param>
<param type="string" name="message">expr:@{WorkflowVariables["message"]}</param>
<param type="string" name="subject">expr:@{WorkflowVariables["subject"]}</param>
<param type="stringlist" name="to">expr:@{WorkflowVariables["destinatiares"]}</param>
<param type="boolean" name="HTML">false</param>
<param type="stringlist" name="files">expr:@{Document["file:content"]},@{Document["files:files"]}</param>
<param type="string" name="viewId">view_documents</param>
</operation>
</chain>
But I keep getting this error:
2014-07-04 16:49:31,203 ERROR [org.nuxeo.ecm.automation.core.operations.notification.SendMail] Error while fetching blobs: Property not found: org.nuxeo.ecm.core.storage.sql.coremodel.SQLBlob@5370ea
2014-07-04 16:49:31,203 ERROR [org.nuxeo.ecm.automation.core.operations.notification.SendMail] Error while fetching blobs: Property not found: [{file=org.nuxeo.ecm.core.storage.sql.coremodel.SQLBlob@1a4a35
One error per file.
Does anyone has ever done this?
Thank you.
07-10-2014 12:54 PM
I found the solution, the xpath has to be declared as string and not as an expresion:
<chain id="envoyerMail">
<operation id="Context.FetchDocument"/>
<operation id="Notification.SendMail">
<param type="string" name="from">expr:@{WorkflowVariables["expediteur"]}</param>
<param type="string" name="message">expr:@{WorkflowVariables["message"]}</param>
<param type="string" name="subject">expr:@{WorkflowVariables["subject"]}</param>
<param type="stringlist" name="to">expr:@{WorkflowVariables["destinatiares"]}</param>
<param type="boolean" name="HTML">false</param>
<param type="stringlist" name="files">file:content,files:files</param>
<param type="string" name="viewId">view_documents</param>
</operation>
</chain>
Attention: Blogs & Forums are in READ-ONLY mode from Oct 9-19 as we transition to our new platform. Learn more.
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.