Track all important actions (user creation, leave approvals, policy changes) for compliance and debugging.
Relevant part of the codebase: Create new backend/app/models.py - AuditLog model, and add logging to critical operations
Expected outcome:
- Create AuditLog model with fields: user_id, action, resource_type, resource_id, timestamp, ip_address, details
- Add audit logging decorator or middleware
- Log all admin actions, leave approvals/rejections, user updates
- Add admin endpoint to query audit logs
- Consider log retention policies
Track all important actions (user creation, leave approvals, policy changes) for compliance and debugging.
Relevant part of the codebase: Create new backend/app/models.py - AuditLog model, and add logging to critical operations
Expected outcome: