3. Indirect Manager Partition: Get the employee's Indirect manager by the organization service.

VB .NET: 

  1.         Public Class EmpIndirectMgrRule
  2.             Implements IRule
  3.             Public Function Execute(ByVal variable As System.Collections.Generic.Dictionary(Of String, Object)) As String Implements HSDc.RingleFlow.Api.Rule.IRule.Execute
  4.                 Dim empId As String = Nothing
  5.                 If (Not variable.TryGetValue("emp", empId)) Then
  6.                     empId = String.Empty
  7.                 End If
  8.                 Dim engine As IWorkflowEngine = WorkflowEngineFactory.GetInstance()
  9.                 Dim emp As IEmp = engine.OrgaisationService.GetEmployee(empId)
  10.                Dim assignee As String = emp.DirectManager.MainDepartment.Parent.MainManager.UserId
  11.                Return assignee
  12.           End Function
  13. End Class

Last edited Jun 25, 2012 at 9:57 AM by cathysung, version 2

Comments

No comments yet.