script that distributes files in different folders from workflow
Moderator: car031
Post
script that distributes files in different folders from workflow
You can help me with a script that distributes files to me in different folders, called files with an attribute assigned with the name "type" in the template and that moves them to different folders when a transition is executed in the workflow.
- Attachments
-
- image.png (17.75 KiB) Viewed 2283 times
Post
Re: script that distributes files in different folders from workflow
Hi Jeyhber,
using the foreach instruction in a script you can cycle throu the documents involved in a task/transition, then using the move tool you can move them in a different fodler
examples:
The getValue can be use to get the vale of a field, then yous can use it combined with the if and set instructions
See also the Javadoc documentation of AbstractDocument and ExtensibleObject classes
For a custom consulting however I suggest you to contact the sales service of LogicalDOC, since the Workflow is an Enterprise feature
bR.
aLEX
using the foreach instruction in a script you can cycle throu the documents involved in a task/transition, then using the move tool you can move them in a different fodler
examples:
Code: Select all
#foreach( $doc in $documents )
$DocTool.move($doc, "InApprovazione")
#end
#foreach( $doc in $documents )
$DocTool.move($doc, "/LogicalDOC Mobile/demo/Approvati")
#end
Code: Select all
$doc.getValue("type")
For a custom consulting however I suggest you to contact the sales service of LogicalDOC, since the Workflow is an Enterprise feature
bR.
aLEX
Who is online
Users browsing this forum: No registered users and 78 guests