cancel
Showing results for 
Search instead for 
Did you mean: 

add action

mannou
Champ in-the-making
Champ in-the-making
hello,

how  can we add a new action?

Thanks
2 REPLIES 2

rivetlogic
Champ on-the-rise
Champ on-the-rise
You can create your own custom actions by extending Alfresco programatically. This is done in two parts: Extending the repository with your action (Java code), and extending the Alfresco Web Client to show your action and collect the necessary parameters for it (Java/JSP code).

You should check out the abstract class:
org.alfresco.repo.action.executer.ActionExecuterAbstractBase.java
That class implements the action interface and takes care of most of the boilerplate functionality leaving you with two methods to implement: The first is the one that specifies the parameters you need to perform your action; and the second is the action implementation itself.

The best way to go about this is to look at an easy action, like:
org.alfresco.repo.action.executer.MoveActionExecuter.java
And leverage most of the code.

As for the Web Client side, look at this file for inspiration:
web-client/source/web/jsp/wizard/create-action/actionmove.jsp

Best of luck.

–Sumer

hfrank
Champ in-the-making
Champ in-the-making
hi,
Could you tell us how to configure the new actions ?

Thanks