How to get the Actioned worklist for the logged in user

  • 25 October 2013
  • 6 replies
  • 2 views

Badge +1

I want to display the worklist with all the worklist items that currently logged in user has worked on. It should not display the worklist items that are currently assigned to him. How can we do this using K2 API?


 


6 replies

Badge +8

You will have to use the Activity Instance Destination SmartObject.  Search specifically for instances with a Status of Completed.  The Destination column will contain the user who actioned the item.

Badge +1

I want to get the Active worklist that user have take action before.

Badge +8

Your question doesn't make sense.  What are you calling the "Active worklist"?


Once a user takes action on a worklist item, it is removed from their worklist so that they don't try to take action on it again.  The only way to access historical information is through the SmartObject I described above.


Perhaps you should describe the problem you are trying to solve?

Badge +13

He probably means an active request that the user has acted on (as approver)...  so in addition to your filter he just needs to filter on process instance status = active.

Badge +1

My requirement is as follows:


Need to display the current logged in user's open items i.e. the items that he has worked on and which are currently in different activity awaiting approval of approvers other than the logged in user. Suppose the logged in user worked on item 1 at activity 1 as he is approver of item1 at activity1. Now the worklist item is at activity2, awaiting for approval of User2.


My worklist should display the following data: ProcessInstanceID, Originator, Process Start Date, Current Activity Name


And, My worklist should not display the completed items. It should display only the active items that tcurrent user worked on.


 

Badge +8

There is not a straight-forward way to get what you want.  It sounds like you are going to need a combination of several SmartObjects.


The Activity Instance Destination SO will get you everything a particular user has taken action on.  See my post above.


The Process Instance SO will get you processes started by a particular user.


Depending on how your processes work, you might need the SO for your particular process.  For example, we allow folks to submit requests on behalf of another person (e.g. an admin on behalf of a VP) and we store these as separate data fields on the process.  When we show a person a list of their requests, we search requests started by a him/her or submitted on behalf of him/her.  To access these data fields, we use the SO created for our process (though you could also use the Process Data SO).


Applying the proper filters to these SmartObjects should get you what you are looking for.

Reply