getOrgUsers Step

Use this step to fetch user's by the organization structure

Last published at: June 25th, 2023

Description:

Get users based on the organization structure.

Inputs

  • workflowUserID – id of the user
  • selectOrgUserType – select user type, manager or reporting users
  • varGlobalForID – variable or global to store the user ids 
 

 

Returns

  • True – step executed successfully
  • False – step failed to execute 
 

 

Usage: 

Example:

Sample Organization Structure:

Let’s build and execute the GetOrgUsersDef example and fetch the user's (MilanD) ManagerID and user's reporting to this person.          

  • Create a new definition called “GetOrgUsersDef”
  • Select the definition and click the “design” button
  • Create a new workflow definition
  • Drag the controls from the toolbox as shown in the graphic
  • Click on the “getWorfklowUserID” step to configure “Settings” properties. Provide the step name. Provide the workflow user name. Provide the variable/global to hold the userID after execution. 
  • The “Logging” setting configuration is necessary for documentation and also measure the workflow progress and the percent complete. This is acheived by configuring the step state and percent fields individually as shown in the images below. Configure the “Logging” using the following properties. 
  • Click on the first “getorgusers” step to configure “Settings” properties. Provide “getOrgUsers (Manager)” as name. Provide the variable/global with contains the workflow userID from above step. Select users type as “Managers”. Provide variable/global which hold the manager UserID after execution.
  • The “Logging” setting configuration is necessary for documentation and also measure the workflow progress and the percent complete. This is acheived by configuring the step state and percent fields individually as shown in the images below. Configure the “Logging” using the following properties. 
  • Click on the second “getorgusers” step to configure “Settings” properties. Provide “getOrgUsers (Report To Me)” as name. Provide the variable/global with contains the workflow userID from above step. Select users type as “Reports To Me”. Provide variable/global which hold the reportee UserID after execution.
  • The “Logging” setting configuration is necessary for documentation and also measure the workflow progress and the percent complete. This is acheived by configuring the step state and percent fields individually as shown in the images below. Configure the “Logging” using the following properties. 
  • Save the process definition, create a new process instance and execute. 
  • Render the process instance. Click on the process step. The process step should get user’s “Manager” and the people “ReportingTo” the user as defined in the FlowWright Organization Structure.