Hi Sharpharp1,
There is a worklist control in smartform toolbar. You can also setup a filters in control properties.
For this scenario, I want to use it to redirect tasks which are NOT assigned to the User...
The worklist control will only show tasks assigned to you....
Hence the Task List in management console which shows the Processes the user has Admin Process rights too.
Can the Worklist control show tasks you have Admin rights too, but not tasks that are assigned to you.
I have a environment with the Worklist Service Broker setup, so I decided to play around with it. It does not fit your requirement.
You will have to consider option 3 then. With the introduction of Management page, there should be a system SmartObject called 'Task' that is being deployed along with your Management.
If you execute that SmartObject in SMO Tester, you should find a method called 'RedirectWorklistItem'. That should be the method that is executed when you perform the redirect on Management. That method will take in the following inputs:
ActionerName - This should be the current user the task is assigned to (eg. K2:DOMAINUserA)
Destination - This should be the user you want to redirect to (eg. K2:DENALLIXUserB)
ProcInstID - The process instance ID of the task
ActInstID - The activity instance destination iD of the task
ID - The ID of the task
You can also use the GetWorklistItems method to retrieve all the worklist items. There is only 1 input for this method, which allows you to filter the worklist items. You will have to enable SmartObject logging, go to Management page, retrieve the worklist items, then check the brokerpackagein.log to determine the format of the input.
Here is a simple filter used for the GetWorklistItems method:
[{"ColumnName":"Process Full Name","Condition":"AND","Comparison":"LIKE","ParameterValue":"K2Project1Process"}]
Yoh Boringnerd,
Thanks for the info, made some progress...
1) Used the Activity Instance Destination SMO in a view and filtered by Active instances of my Process Name to display a specific list for that Form (Yippee)
2) Changed the layout fields, so the Supervisors only see what they need to.
So that's Part 1 complete, the Management Page isn't needed to see the TASK LIST
Now Part 2, the redirection..... To work out how to REDIRECT the Task, when a Supervisor double-clicks one of the Tasks in the List.
As you suggested, i loaded up the Task SMO in the Tester Tool and picked Method RedirectWorklistItem.
I used the getworkitems method to get the various item numbers and it works manually via the tester tool
Gonna add 2 filters 1) procname and 2) processinstancestatus = Active (is this right? should only give me current LIVE instances awaiting an action)
Now, i'm gonna throw all of this into a form with 2 views and see if i can get it working through a smartform... fingers crossed
Got it working.... Thanks for your help with this BoringNerd.
All possible to select new destination user and redirect the task via Smartforms.... just one issue which i'll post a new thread on
@BoringNerd
WOW. This is so timely. This is exactly what I was looking for. Thank you!!