Entities & Relations
ImLate manages several core entities. This page explains what they are and how they relate to each other.
Visitor
A Visitor is any person who can sign in or out of the facility.
| Field | Description |
|---|---|
| Name / Surname | Full name of the visitor |
| Contact email (optional) | |
| Is Student | Whether this visitor is a student |
| Grade | Year group / grade (students only) |
| Image | Photo displayed on sign-in (max 5 MB) |
| iSAMS ID | Link to the school ERP record (if synced) |
| School ID | School-assigned identifier |
Visitor Keys
Each visitor can have one or more RFID keys linked to their account. A key is identified by a unique key_id string.
- Keys are used for scanning at the RFID reader terminal.
- A key belongs to exactly one visitor.
- Keys can be added or removed via the Admin Panel → Visitors.
INFO
ERP-synced visitors are read-only. If a visitor was imported from iSAMS (has an iSAMS ID), their profile fields (name, surname, year group, school ID) are managed by iSAMS as the single source of truth and cannot be edited in ImLate. Only RFID keys can be added or removed locally. See ERP Integration.
User
A User is an account that can log in to the Admin Panel.
| Field | Description |
|---|---|
| Username | Unique login name |
| Password | Stored as a bcrypt hash |
| Name / Surname | Display name |
| Role | admin (full access) or terminal (limited) |
| Is Active | Whether the account can log in |
| Created By | ID of the admin who created this user (nullable, used for terminal users) |
INFO
Users and Visitors are separate entities. A User manages the system; a Visitor uses the sign-in terminals.
Track
A Track is a single sign-in or sign-out event.
| Field | Description |
|---|---|
| Visitor ID | Which visitor performed the action |
| Key ID | Which RFID key was used (if any) |
| Sign In | Whether this is a sign-in (true) or sign-out (false) |
| Terminal ID | ID of the terminal device that recorded this event (for RFID scans) |
| Admin ID | ID of the admin who performed manual tracking (for manual entries) |
| Created At | Timestamp of the event |
Schedule & Registration Periods
When ERP integration is enabled, the system uses Schedules to track registration periods throughout the day.
| Concept | Description |
|---|---|
| Registration Period | A time window (e.g., 8:00–8:30 AM) during which attendance is recorded |
| Main Registration | The primary period (usually AM) used to determine if a student is late or absent |
| Lesson Periods | Additional periods for individual classes |
Entity Relationships
Visitor ──┬── has many ──▸ Visitor Keys
│
└── has many ──▸ Tracks (sign-in / sign-out events)
User (admin) ──── logs in to ──▸ Admin Panel
User (terminal) ── authenticates ──▸ RFID Terminal
Track ──── recorded by ──▸ Terminal (terminal_id) or Admin (admin_id)
Schedule ── contains ──▸ Registration Periods