cancel
Showing results for 
Search instead for 
Did you mean: 

Fire custom action on checkin

sankatha
Champ in-the-making
Champ in-the-making
Hi All

I have a custom action which I like to call upon a file checkin. Currently I have created a rule which calls the the action upon every node creation and update and I manually check whether the node is actually checked-in by using my own logic which I think is not very good  :cry: (The custom login simply evaluates some version numbers and created times and takes a simple decision).

Is there a better way of calling an action directly on a file check-in. Is there some kind of a listener which I can implement ? I am new to Alfresco. Any help will be greatly appreciated.
1 REPLY 1

patil
Champ on-the-rise
Champ on-the-rise
Hi,

   <!– Checkin document –>
         <action id="checkin_doc">
            <evaluator>org.alfresco.web.action.evaluator.CheckinDocEvaluator</evaluator>
            <label-id>checkin</label-id>
            <image>/images/icons/CheckIn_icon.gif</image>
            <action-listener>#{CheckinCheckoutDialog.setupContentAction}</action-listener>
            <action>dialog:checkinFile</action>
            <params>
               <param name="id">#{actionContext.id}</param>
            </params>
         </action>

Change the action listener implemetation to put your custom logic.

Thanks,
Patil
Cignex Technologies
Bangalore