cancel
Showing results for 
Search instead for 
Did you mean: 

Preview of a generated document in a form

r_kister
Champ on-the-rise
Champ on-the-rise

Hello,

I have created with BPMN editor a process that generate a document. In a next task, i would like to display this document in a form to allow the task assignee to view it.

I would like to have the same functionnality as if the generated document was an uploaded document : in the form, a link is display and if the user click on it, a popup is displayed with a preview of the document.

Is it possible and how can i do ?

Raphael

1 ACCEPTED ANSWER

cjose
Elite Collaborator
Elite Collaborator

Hi Raphael,

This is possible if you use a display value (instead of display text). The generated document variable will be available for you to select in the DisplayValue->Variable->SelectVariable (dropdown).

Also, the generated document is automatically linked to the process and you can preview it from there as well by going into the process list. App->Processes->Select your running process instance.

Regards,

Ciju

View answer in original post

5 REPLIES 5

yogeshpj
Star Contributor
Star Contributor

Which forms you are using  ? Alfresco share or Activiti ?

r_kister
Champ on-the-rise
Champ on-the-rise

Hello,

My forms are in Activiti Suite.

I would like to preview a generated document from an activiti form.

To preview an uploaded document from a form, i use the component "Display Text" and in the text to display, i just put this value : ${name_of_attachFile_field}.

With this method, i have a link in my displayed form and when click on it, it display a popup with a preview of the uploaded document.

But, it doesn't work with a generated document as we only get the ID of this content.

Is it possible to have the same link as an uploaded document and how can i do ?

Raphael

cjose
Elite Collaborator
Elite Collaborator

Hi Raphael,

This is possible if you use a display value (instead of display text). The generated document variable will be available for you to select in the DisplayValue->Variable->SelectVariable (dropdown).

Also, the generated document is automatically linked to the process and you can preview it from there as well by going into the process list. App->Processes->Select your running process instance.

Regards,

Ciju

r_kister
Champ on-the-rise
Champ on-the-rise

Thank you Ciju, it works fine when using Display Value.

Regards,

Raphael

prohit
Champ on-the-rise
Champ on-the-rise

Hi Jose and team,

We know how to use display value for attachment and it generates preview automatically but i have a situation where i do not want preview to enable in display value, could you kindly provide some solution for this. 

Requirement:

User1 will upload the documents

User2 will have view option but not editable, also this attachment should not preview because when ever it previews user2 will have to scroll down to the bottom to select other fields and this is causing trouble.

Your suggestions would realy help me.