Skip to content

Workflow Engine (WFL)

Module Purpose: The rules engine. It automates permissions, approvals, and process flows. It ensures no user can bypass authority limits (e.g., Sales Rep approving a ₹1 Cr quote).

[!TIP] Core Concept: "Trust but Verify." Every critical action (Discount > 10%, Credit Limit Override) requires a digital signature (Approval) stored in the audit trail.


Use Case Quick Reference

ID Title Priority
WFL-001 Create Workflow Template P1
WFL-002 Define Approval Chain P1
WFL-003 Route Document for Approval P1
WFL-004 Send Approval Notifications P1
WFL-005 Track Approval Status P1
WFL-006 Handle Rejections/Revisions P2

UC-WFL-001: Create Workflow Template

What It Does

An Admin tool to design process flows graphically. It allows defining "Stages" (Review -> Approval -> Verification) and "Conditions" (Value > 10k).

Who: System Admin
When: Setup


How It Works

  1. Template Name: "High Value Quote Approval".
  2. Triggers: Condition Quote Value > ₹50,00,000.
  3. Stage Design:
  4. Stage 1: Sales Head (SLA: 4 hours).
  5. Stage 2: Finance Director (SLA: 24 hours).
  6. Logic: Both stages must pass for final status "Approved".

UC-WFL-002: Define Approval Chain

What It Does

Maps "Roles" to "People". It handles hierarchy logic like "Reporting Manager" so you don't need to hardcode names in every workflow.

Who: Admin / HR
When: Setup


How It Works

  1. Role Mapping:
  2. Role: Regional Manager = "Rahul", "Priya".
  3. Role: CFO = "Mr. Mehta".
  4. Hierarchy Rule:
  5. If Submitter = "Sales Rep A", then Reporting Manager = "Regional Manager (West)".
  6. Delegation:
  7. "Mr. Mehta" is on leave? Auto-delegate to "Deputy CFO".

UC-WFL-003: Route Document for Approval

What It Does

The runtime engine. When a user clicks "Submit for Approval" on a Quote/PO, this engine grabs the document, locks it, and finds the right approver.

Who: System Engine
When: User Action


How It Works

  1. Lock: Document status changes to Pending Approval. Edit Access = Read Only.
  2. Find Approver:
  3. Workflow: "Invoice Approval".
  4. Step 1: "Manager". System looks up Submitter's Manager -> "Steve".
  5. Queue: Add task to Steve's "Inbox".

UC-WFL-004: Send Approval Notifications

What It Does

Ensures the approver knows there is work waiting. Uses multi-channel pings to drive faster Turnaround Time (TAT).

Who: System Notifier
When: New Task in Inbox


How It Works

  1. Instant: Push Notification to Mobile App.
  2. Email: "Action Required: Quote #123 waiting for approval." (Contains "Approve/Reject" buttons directly in email).
  3. Reminder: If untouched for 4 hours -> SMS "Urgent: Pending Approval".

UC-WFL-005: Track Approval Status

What It Does

The "FedEx Tracking" for approvals. Submitters can see exactly whose desk the file is stuck on.

Who: Submitter (Sales Rep)
When: Checking Status


How It Works

  1. Timeline View:
  2. 10:00 AM: Submitted by You.
  3. 10:05 AM: Approved by Manager (Steve).
  4. Current: Pending with Finance (Mr. Mehta) since 2 hours.
  5. Nudge: Button to "Send Reminder" to the current blocker.

UC-WFL-006: Handle Rejections/Revisions

What It Does

Handles the "No". If an approver rejects, they must provide a reason. The workflow then routes back to the submitter for correction, not to the start.

Who: Approver
When: Rejecting


How It Works

  1. Input: Approver clicks "Reject".
  2. Mandatory: System prompts "Enter Rejection Reason" (e.g., "Margin too low").
  3. Routing: Document Status -> Draft (Changes Requested).
  4. Notify: Email Submitter "Rejected: Margin too low. Please fix and resubmit."
  5. Resubmit: Logic resets mostly, but keeps "Version 2" history.

← Back to Use Cases