-
1. Re: getting group specific tasks
swiderski.maciej Apr 7, 2014 1:47 AM (in response to arif.mohammed)group based queries rely on UserGroupCallback information so make use when you issue query you have UserGroupCallback registered that is aware of your users and groups and then use regular queries for given user so it will fetch group tasks for that user according to his/her group membership.
HTH
-
2. Re: getting group specific tasks
arif.mohammed Apr 7, 2014 12:18 PM (in response to swiderski.maciej)Yes I have registered UserGroupCallback and user to group mapping is working fine but here the issue is different. Though a particular user say usr1 belongs to 2 groups say group1 and group2, I would like to retrieve the tasks assigned to usr1 and group1(excluding group2 tasks). As of now the queries are based on user name not the group name. As I said there is one method getTasksAssignedAsPotentialOwnerByStatusByGroup but it is deprecated. I have to call this method as follows getTasksAssignedAsPotentialOwnerByStatusByGroup(null, groupIds,sts,locale); where groupIds contain just "group1". Once I get this list I have to remove the tasks which are not owned by "usr1".
-
3. Re: getting group specific tasks
arif.mohammed May 2, 2014 12:15 AM (in response to arif.mohammed)Hello jBPM Team.
My requirement is very simple as explained above. I have a customized task list in my application and I would like to retrieve the tasks associated to a group no matter who are the users in that group and no matter who am I(as a user). I was using deprecated API getTasksAssignedAsPotentialOwnerByStatusByGroup in 5.4 and it is removed in version 6. If there is no alternative API how can I extend the existing API to fulfill the above requirement ? Can I write my own JPA queries ?
-
4. Re: getting group specific tasks
swiderski.maciej May 2, 2014 1:26 AM (in response to arif.mohammed)some methods are still available in the InternalTaskService so cast the TaskService instance to get access to them.
HTH
-
5. Re: getting group specific tasks
arif.mohammed May 2, 2014 1:31 AM (in response to swiderski.maciej)But we are not supposed to use internal API's right. I am trying to use getTasksByVariousFields(null,null,null,null,groupList,null,statusList,null,true); At a first glance it looks convincing but there is no documentation and I have to look how does it fit to my need. Will this method work for my case ?
-
6. Re: getting group specific tasks
swiderski.maciej May 6, 2014 1:38 AM (in response to arif.mohammed)everything that is inside kie-internal is sort of in transition to become (eventually) the public api so I would say it's safe to use it with note in mind that it might change over the releases but usually it's kept backward compatible.
The getTaskByVariousFileds is more a technical method and should not be used by client code directly as this is still something that might change over time so I would recommend to stick to more dedicated methods instead.
HTH
-
7. Re: getting group specific tasks
arif.mohammed Dec 18, 2015 6:13 PM (in response to swiderski.maciej)Hi Maciej,
I was using InternalTaskService and it was working fine until 6.1.0.Final but all of a sudden this behaviour is changed in 6.3.0.Final. This feature is very much needed, not sure why it does not work. Can you please look at this thread https://developer.jboss.org/thread/266789
Is there any other alternate way of writing custom queries to fetch the task details (example providing our own orm.xml)
Note: The author of the above thread was me, I forgot the old ID so has to create the new one.