Role Definition 

Use

You use this function if you want to define more roles in addition to the roles delivered by SAP.

Prerequisites

Before you start defining roles, you must start the workflow process.

  1. Decide what you want the workflow to achieve, and break it down to the smallest meaningful units of work. These units of work become single-step tasks in your workflow.
  2. Select the objects you require. To do so, create a business object or use one of the existing objects. You should be able to find an object that you can use in the Business Object Repository.
  3. Each task accesses an object method. Make sure that the methods you require already exist.
  4. Create the tasks, or use the existing tasks. Define the possible agents for the task in the task definition.
  5. Group the tasks together in the workflow.
  6. Assign agents to the work items in the workflow definition. They must be a subset of the possible agents for the task. If this is not the case, the work item is not executed.

You can do this manually, as a 1:1 assignment, or by using role resolution.

For more information, see SAP Business Workflow.

Features

When defining a role, you determine

This information constitutes the role parameters. They are defined as elements of the role container.

The role resolution procedure is determined by the role type.

The Responsibilities Role Type

When role resolution is performed, an assignment table is evaluated in which Organizational Management objects (jobs, positions, users, organizational units) are assigned to the various characteristics of the role parameters. This assignment table was explicitly created during role definition.

For more information, see Define Roles Using Responsibilities.

The Organizational Data Role Type

When role resolution is performed, the system evaluates SAP organizational objects, such as materials controller, planner group, shipping point, or sales office, which are maintained in the master data of an application object.

This type of role resolution requires the use of a separate maintenance transaction independent of role definition to create assignments between the SAP organizational objects and the organizational objects in Organizational Management (jobs, positions, users, organizational units) with which they are related.

For more information, see Define Roles Using Organizational Data.

The Function to be Executed Role Type

When role resolution is performed, a function module is accessed that then facilitates evaluations as required. A table that is maintained in Customizing is evaluated by the function module. The function module must adhere to a given interface, and is specified during role definition.

For more information, see Define Roles Using Function to be Executed.

Role Resolution Based on Evaluation Paths

When role resolution is performed, the system uses information that is available in Organizational Management on the basis of relationships between individual objects that are maintained in an organizational plan.

This information can be used, for example, if you need to determine the head of an organizational unit, or the remaining members of the organizational unit, starting from the initiator of the workflow.

From a technical perspective, this role resolution is very similar to role resolution by executing a function module. The RH_GET_STRUCTURE function module must be used; an evaluation path is also specified.

For more information, see Role Resolution Using Evaluation Paths.

Activities

If you want to use role resolution to restrict the number of possible agents for a work item in a workflow, you must:

  1. Choose SAP menu ® Tools ® Business Workflow ® Development ® Definition tools ® Standard roles to select the tools used to define roles
  2. Decide how you want to find agents in the system, that is, using function modules, organizational data, or responsibilities
  3. Create a container definition (not for the organizational data role type)
  4. Binding is automatically suggested for the workflow. Confirm that the fields in the role container are compatible with the fields in the workflow container.
  5. Start the workflow.

At runtime, role resolution provides you with a table containing a set of possible agents. These agents are determined at runtime using the values assigned to the role container elements.