2025-12-08 03:18:25 +00:00
|
|
|
"""
|
|
|
|
|
Conditional field requirements configuration.
|
|
|
|
|
|
|
|
|
|
Reference configuration for which fields are typically required
|
2026-09-26 11:23:22 +00:00
|
|
|
based on status. These are NOT enforced at the model
|
2025-12-08 03:18:25 +00:00
|
|
|
level but can be used by serializers or frontend for validation hints.
|
|
|
|
|
"""
|
|
|
|
|
|
|
|
|
|
# Lead: Suggested required fields by status
|
|
|
|
|
LEAD_REQUIRED_BY_STATUS = {
|
|
|
|
|
"assigned": [],
|
|
|
|
|
"in process": [],
|
|
|
|
|
"converted": ["email"], # Only email is enforced
|
|
|
|
|
"recycled": [],
|
|
|
|
|
"closed": [],
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# Case: Suggested required fields by status
|
|
|
|
|
CASE_REQUIRED_BY_STATUS = {
|
|
|
|
|
"New": ["name", "status", "priority"],
|
|
|
|
|
"Assigned": ["name", "status", "priority"],
|
|
|
|
|
"Pending": ["name", "status", "priority"],
|
|
|
|
|
"Closed": ["name", "status", "priority", "closed_on"],
|
|
|
|
|
"Rejected": ["name", "status", "priority"],
|
|
|
|
|
"Duplicate": ["name", "status", "priority"],
|
|
|
|
|
}
|