Jump to content

Unable to assign a Request created in workflow to the team selected in Human Task User Group Picker


Berto2002
 Share

Recommended Posts

Am I doing this correctly?

A Human Task to capture which team should get the Ownership of a new Request created by workflow:

image.png.13029f15a6735db08de9e2840cbcf132.png

That task outputs to the TimeLine with the "Assigned Team" and then I have added an additional Update Timeline node to see the result.

image.png.81c094f04e1e7a5efe60f10e4a898a97.png

Note that the Timeline gets the full 'system name' of the team, complete with the spelling mistake that is present in the Organisation Group ("...Suppirt")

image.png.d358cc76bc74e70c523da7915c50d3ca.png

I then have a node that creates a new Request and the Assigned Team outcome from the Human Task is added as the Team for the new Request: "&[functions.getTaskAnswers("task-9812e30a").ActionTeam]"

image.png.baaa3e4e94911b649af1a1e0b9b529e2.png

But it does not pick-up that team when it is logged.

It feels like the User Group picker on the Human Task is giving a result that the Assigned Team node of the Log New Request cannot interpret. The same is true whichever team I select.

image.png.d9364f5852f976c33726fb99cf4771f5.png

Any help appreciated.

Berto2002

Link to comment
Share on other sites

28 minutes ago, Berto2002 said:

But it does not pick-up that team when it is logged.

It would not... the reason is that the group picker for the team (or any other organisation type) will return the entity value which for a team is prefixed with the "urn:sys:group:...". And indeed, the "the Assigned Team node of the Log New Request cannot interpret" but more precisely is not that it cannot interpret, is simply not a valid value for an existing team ID as far as the "Log New Request" node is concerned. Based on your example, as you are using the "Log New Service Request" option, this is in essence using the Log Service Request API. Looking at the documentation for this API, the "teamID" input param (which is what the node uses for Team) is: "The Id of the team assigned to the Request. This is the h_id value of the record in the h_sys_groups table for the assigned team.". Again, looking in h_sys_groups table the values for h_id do not contain the entity prefix. One of the solutions to overcome the issue in your scenario is to strip the entity prefix from the returned team value, since it is a fixed string, regardless of what team is selected in the picker. So one can use the Core/Collaboration string utilities and remove that prefix prior to using that value in the "Log New Service Request" node. Here is an example of this, using a team name as "Test".

image.png

The value for Input Text parameter can be a variable, such as the selection from the picker in a previous task. In this example we assume the value for the variable is "urn:sys:group:Test".

Link to comment
Share on other sites

@Victor hahahahahaha!

I very much appreciate your explanation and the solution proposed has worked! This is a very useful feature. I assume the same is true for when the User Picker operates.

May I rhetorically ask, though, that I hope you can see this was not at all intuitive for a Hornbill user like myself. I am not sure many of us out here would have ever discovered that as a solution. May I suggest you run an internal enhancement request to see if that can be improved?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...