I’ll provide a complete solution that addresses workflow step configuration, conditional validation rules, and approval step dependencies for your risk-based compliance workflow.
Workflow Step Configuration:
The root cause is that qual-2022.1 treats conditional approval steps differently than truly optional steps. When you configure the QA approval step as “conditional,” it still registers in the workflow history, and the default validation checks for completion of all registered steps. You need to reconfigure the step using explicit conditional routing rather than marking it as conditional.
In your workflow design, set up the routing like this:
- After regulatory review step, add a decision gateway
- Decision condition: IF compliance_item.risk_level = ‘high’ THEN route to QA_approval_step ELSE route directly to final_release_step
- This ensures low-risk items never enter the QA approval step, so it won’t appear in workflow history
Conditional Validation Rules:
At your final release step, modify the validation configuration to use conditional logic. Navigate to Admin > Compliance > Workflows > [Your Workflow] > Release Step > Validation Rules. Replace the current approval validation with:
// Pseudocode - Conditional approval validation:
1. Check if compliance_item.risk_level equals 'high'
2. IF high risk: Validate that approval_qa_status = 'approved' AND approval_regulatory_status = 'approved'
3. IF low/medium risk: Validate only approval_regulatory_status = 'approved'
4. Return validation result with specific error message if failed
This ensures validation only checks for QA approval when the risk level actually required that step.
Approval Step Dependencies:
The issue with your current configuration is that approval step dependencies are defined at the step level, but they don’t account for conditional routing. You need to move the dependency logic to the transition level instead.
For each transition leading to the final release step:
- Transition from QA approval (high-risk path): Require approval_qa_status = ‘approved’
- Transition from regulatory approval (low-risk path): Only require approval_regulatory_status = ‘approved’
- Remove the global dependency that requires all approval steps
Validation Lifecycle Configuration:
The final piece is updating your validation lifecycle rules. In Admin > System Settings > Validation Configuration, locate the compliance record validation rules. Add a new rule specifically for approval validation:
Rule Name: Risk-Based Approval Validation
Trigger: On transition to Released state
Condition: Apply conditional logic based on risk_level attribute
Validation Logic: Check only the approvals required for the actual workflow path taken
Testing Your Configuration:
After making these changes, test with both high-risk and low-risk compliance items:
- High-risk item should route through both regulatory and QA approval, with validation requiring both
- Low-risk item should bypass QA approval entirely, with validation only checking regulatory approval
- Verify the workflow history shows only the steps actually traversed
- Confirm validation error messages are specific about which approval is missing
This approach eliminates the validation failure for skipped steps because those steps never enter the workflow history. The conditional validation rules ensure you’re only validating approvals that were actually required based on the risk level, maintaining your risk-based approach while satisfying the validation engine’s requirements.