cancel
Showing results for 
Search instead for 
Did you mean: 

Extension of task-instances workflow webscript

vojtechm
Confirmed Champ
Confirmed Champ

Hello,

I'm trying to extend workflow webscript org/alfresco/repository/workflow/task-instances for one argument more.

What is the best practice in this case? I know that I must override the task-instances.get.desc.xml file and add my argument to <URL> and <args> section but what else? Is there some webscript's "main" JS file which I can extend to ensure the functionality?

Thank you very much.

1 ACCEPTED ANSWER

afaust
Legendary Innovator
Legendary Innovator

Unfortunately, that web script is implemented as a Java-backed web script. Extending it is generally pretty tricky. The class in question is "TaskInstancesGet" found in the alfresco-remote-api sub-project. Modifying the task-instances.get.desc.xml is not necessary at all for adding a new URL parameter - URL parameters included in the "url" element of that file are purely informative and there is no functional requirement to list them there.

View answer in original post

3 REPLIES 3

afaust
Legendary Innovator
Legendary Innovator

Unfortunately, that web script is implemented as a Java-backed web script. Extending it is generally pretty tricky. The class in question is "TaskInstancesGet" found in the alfresco-remote-api sub-project. Modifying the task-instances.get.desc.xml is not necessary at all for adding a new URL parameter - URL parameters included in the "url" element of that file are purely informative and there is no functional requirement to list them there.

vojtechm
Confirmed Champ
Confirmed Champ

Hello,

that helped me a lot!

In case I want to override bean id of alfresco-remote-api sub-project "webscript.org.alfresco.repository.workflow.task-instances.get", what would be the best place to put my custom java files with *-context.xml file for alfresco to load such bean?

Thank you.

Ok, I found the answer - Customizing bean files | Alfresco Documentation 

Thank you for help.

Getting started

Explore our Alfresco products with the links below. Use labels to filter content by product module.