Get all the pending requests

  • 10 December 2007
  • 3 replies
  • 2 views

Badge +1

Hi All,


I want to write  a k2.net application that can allow the manager to view and approve/deny all the pending requests sent by the Employees.


Presently I am able to redirect the Manager to the Approval Page from an Email with a link provided consisting of SERIAL number.


But I want this to be taken care in Approval page where the Manager can see all the requests sent by the Employees in some Grid from where he can approve or reject the request.


Any hint to the solution would be  appreciated. If you any example code for the same will be a great help for me.


 


Thanks you all.


 


 


 


 


 


3 replies

Badge +9

You will want to use the K2ROM API for this.  This should be covered in the K2 documentation.


At a high level, you'll want to create a page that Opens a K2ROM Connection object, then calls the Connection.OpenWorklist() method for this user.  This method returns a Worklist object which is a collection of WorklistItem objects.


You can then bend these WorklistItems to a grid and provide the ability to approve them all at once (probably checkboxes on the grid items).  Once the Manager makes his/her selection, you'll utilize K2ROM again to open a connection to K2, then for each selected item, call OpenWorklistItem with the K2 serial number (which returns a WorklistItem object0, and then call WorklistItem.Finish().


HTH.

Badge +1

Bob,


 


Thanks for your quick reply. I will work on it and let you know the status.

Badge +1
That worked good. Thanks you Bob ones again, hope to get more on k2 from this forum. 

Reply