Chapter 10: Workflow and Approval




This chapter demonstrates advanced features of workflow and approval. Our requirement requires custom workflow and approvers from various sources. This chapter, you will learn how to:
§  Generate event and workflow.
§  Set approver by API.
§  Using velocity email template in workflow.
§  Implement time out.



10.1 Requirement

Administrator requests access CRM or HR application for employee. The requirements can be written as steps:
  • Entry employee number and check request CRM Application or HR Application.


    • Each request has own workflow.


Figure 10-1 shows request form

  • If CRM Application is checked, generate workflow Request CRM Application
    • Require one approver, HR System’s web services provide approver list.
    • If request approved, and send ticket. 
  • If HR Application is checked, generate workflow Request HR Application
    • The first approver is member of admin role “User Approver”
    • If employee’s location is North America require the second approvers, for somewhere else requires only the first approver.
      • The second approvers are list in properties file.

    • If request approved, add provisioning role “BookPrj.HR”
    • If request time out, request will be rejected automatically.
    • Email notification requirement:
      • Request is waiting
        • Send email to all approvers.
      • Request has been waiting for 5 minutes. (For testing, we set 5 minutes for alert)
        • Send email to all approvers.
      • Time out (For testing, we set 10 minutes for timeout)
        • Send email to all approvers.
      • Request rejected.
        • Send email to requester.

10.2 Design

.  END OF SAMPLE









Figure 10-3 shows one workflow generate 2 workflows (attached with event)
                
                Request CRM Application workflow










No comments:

Post a Comment