cancel
Showing results for 
Search instead for 
Did you mean: 

Agent Assignment with Roles / Custom FM Rule

Former Member
0 Kudos

Hi All,

       This may have been asked earlier but I could not find a relevant thread so posting it here. Here is the situation. I have a custom rule which returns a Org Unit . Org Unit has some positions/users under it. So I get to a list of users. Now in the standard task I have assigned few roles. If I look at PFCG the users are listed there. But the workitem does not reach the users. Is it because the way standard task is set up? I mean do I have to assign users/org unit rather than task? If thats the case why ? I mean the flow from Org Unit -> User and Role -> User takes me to same user.

When I debugged the agent assignment I see that I get an exception from RH_TASK_AGENT_CHECK FM which says Org Unit is not a valid agent for the task.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

As I suspected the issue was my authorization when I assigned the roles to the task . I did not have enough authorization and I tried to by pass some checks in debug mode while assigning the roles. I must have missed some part of it. I just assigned it after getting all the authorizations and it worked. Closing the thread.

Jocelyn_Dart
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi,

Firstly - please give yourself a proper name.  ABAP ABAP does not encourage people to trust you.

Secondly, remember that the recipients are the intersection of the Possible agents (i.e. security which are your roles) and the Responsible agents (your custom rule).  Normally we would assign both to either positions or to users.  Sending to a whole team via an org unit is possible but not usual.

You can check which users are found for your org unit by running function module RH_STRUC_GET with eval path SAP_TAGT.   Then check that at least one of those users has at least one of the roles assigned to the task.

If you can confirm the above are all assigned correctly, then yes it is likely to be authorizations issues.  So check that all your users have access to read TS and WS objects, and that sufficient authorizations for authorization object PLOG have been assigned to allow the relevant org unit to user relationships to be read.

Hope that helps.

Regards,

Jocelyn

Former Member
0 Kudos

Try changing the task to General Task. If it works, then the issue is with task agent assignment. You might need to add the org unit to the list of possible agents.

Former Member
0 Kudos

The issue is with the agent assignment only. But now that I look at Production box the assignment as I did should work. I had some authorization issues while assigning roles to the task and I bypassed the auth checks in debug mode. May be I missed some internal auth objects and the assignment is not proper.