Populate Multi-instatiated file control using Document object

1
0
-1

Hi,

I have a form with a multi-instantiated group widget having a date and file control. I have a task with a self loop to upload a file for specific date. I upload the file to alfresco and show the same task again. My ask is to show the uploaded file in the group widget such that I see a list of files as below

Date 1 - > File 1 Date 2 -> File 2 ...

I tried achieving this by creating a variable of type List<Map<String,Object>> and on click of submit I populate a this variable.

Document doc = apiAccessor.getProcessAPI().getLastDocument(processInstanceId, "mainDoc"); DocumentValue docValue=new DocumentValue(apiAccessor.getProcessAPI().getDocumentContent(doc.getContentStorageId()), doc.getContentMimeType(), doc.getContentFileName());

targetMap.put("date", field_date); targetMap.put("file", docValue);

On the group widget I just use targetMap as the inital value, but every time I run this it shows only date field. The file field is not populated.

Any ideas?

Comments

Submitted by ttoine on Thu, 05/22/2014 - 17:11

sometimes we have issues with the alfresco connector. maybe you should try with the cmis connector ?

No answers yet.
Notifications