Institution Audit History - hmislk/hmis GitHub Wiki
Institution and Department Audit History
Overview
The Audit History feature provides a complete, tamper-proof record of every action performed on an institution, department, or site. Every time a record is created, edited, activated, deactivated, or deleted, the system records who made the change, when it was made, and exactly what was changed.
When to Use
- Verify who created or last modified an institution, department, or site
- Investigate unexpected changes to a record's details
- Review the activation/deactivation history
- Support internal audits and compliance reviews
- Confirm that a specific change was saved successfully
How to View Audit History
- Navigate to the relevant management page:
- Manage Institutions for institutions
- Manage Departments (Own) or Manage Departments (All) for departments
- Manage Sites for sites
- Search for and select the record
- Click History (clock button)
- The audit events page opens with the full change log
Understanding the Audit Events Page
Record Summary
At the top of the page, a summary panel shows key details about the selected record:
For Institutions:
- Name - the institution's current name
- Code - the institution's code
- Status - current status displayed as a green Active or red Inactive badge
- Institution Type - the type of institution
- Address - the institution's address
- Total Audit Events - the total number of recorded events
For Departments:
- Name - the department's current name
- Code - the department's code
- Status - current status displayed as a green Active or red Inactive badge
- Department Type - the type of department
- Institution - the parent institution
- Site - the associated site
- Total Audit Events - the total number of recorded events
Events Table
The main table lists all audit events in chronological order with the following columns:
| Column | Description |
|---|---|
| Date / Time | When the action was performed |
| Action | The type of action, displayed as a colour-coded badge |
| User | The name of the user who performed the action |
| Changes | A detailed summary of what was changed (field-by-field differences) |
| Status | Whether the action completed successfully or failed |
| IP Address | The IP address from which the action was performed |
Action Types
Each action is shown with a colour-coded badge for quick identification:
For Institutions:
| Action | Colour | Meaning |
|---|---|---|
| Create Institution | Green | A new institution was added to the system |
| Update Institution | Yellow | An existing institution's details were modified |
| Delete Institution | Red | An institution was permanently deleted |
| Activate Institution | Teal | An inactive institution was reactivated |
| Deactivate Institution | Grey | An active institution was deactivated |
For Departments:
| Action | Colour | Meaning |
|---|---|---|
| Create Department | Green | A new department was added to the system |
| Update Department | Yellow | An existing department's details were modified |
| Delete Department | Red | A department was permanently deleted |
| Activate Department | Teal | An inactive department was reactivated |
| Deactivate Department | Grey | An active department was deactivated |
Pagination
The table supports pagination for records with many audit events:
- Use the page navigation controls at the top and bottom of the table
- Change the number of rows displayed per page: 10, 20, 50, or 100
- The current range is shown (e.g. "1-20 of 45 events")
Page Controls
- Back - returns to the management page
- Refresh Events - reloads the audit events to show the latest data
Best Practices
- Check audit history before editing a record to understand its recent changes
- Use the Changes column to see exactly which fields were modified in each update
- Review the User column to confirm accountability for changes
- Look at the Status column to verify that actions completed successfully
FAQ
Q: Can audit records be edited or deleted? A: No. Audit records are permanent and cannot be modified or removed by any user.
Q: How far back does the audit history go? A: The audit history retains all events from the time the record was first created. There is no time limit.
Q: Why does the Changes column sometimes appear empty? A: For actions like Activate or Deactivate, the only change is the status itself, so the detailed changes field may show just the status change.
Q: Is audit history available for all entity types? A: Yes. Institutions, departments, and sites all have audit history.