Dashboards
Build custom dashboards with drag-and-drop widgets, KPI cards, and charts — per role or personal
Overview
OptiCRM's dashboard system lets admins and users build custom dashboards by adding, positioning, and resizing widgets on a drag-and-drop grid. Each dashboard can show KPI numbers, bar charts, line charts, pie charts, funnels, and more — all powered by live data from the KPI engine.
Dashboards support three visibility scopes:
- Personal — only the creator sees it
- Role-scoped — visible to users with specific roles (e.g., Finance Officer, HOD)
- Institution-wide — visible to everyone (used for the default dashboard)
The Main Dashboard
The main page (/) automatically loads the best matching dashboard for the current user:
- Personal dashboards (if the user created one) — highest priority
- Role-scoped dashboards (matching the user's role)
- Institution default (the dashboard marked as default)
- Fallback — if no dashboards exist, shows the classic static KPI layout
Dashboard Switcher
When a user has access to multiple dashboards, a dropdown appears next to the title. Click to switch between dashboards instantly.
Auto-Refresh
Dashboard data refreshes automatically every 5 minutes. Click the refresh icon in the header to refresh manually.
Creating a Dashboard
Navigate to Settings > Dashboards and click New Dashboard.
Name and Scope
Give your dashboard a name (e.g., "Finance Overview") and choose its scope:
- Personal — only you can see it
- Role Scope — visible to specific roles
- Institution Scope — visible to everyone
Add Widgets
Click Edit to enter edit mode, then click Add Widget. For each widget, configure:
- Title — display name (e.g., "Fee Collection MTD")
- Chart Type — KPI Number, Bar Chart, Line Chart, Pie Chart, Donut, Area, Gauge, or Table
- Data Source — what data to display (see Data Sources below)
- Column Span — how wide the widget is (3, 4, 6, 8, or 12 columns)
Drag and Drop
In edit mode, widgets are draggable and resizable:
- Move — grab the move icon (top-left of each widget) and drag to a new position
- Resize — drag the bottom-right corner to make widgets larger or smaller
- The grid snaps to a 12-column layout automatically
- Changes are saved when you click Save
View Mode
Click View Mode to see the dashboard with live data. Charts render with real KPI values from your institution's data.
Widget Types
| Type | Description | Best For |
|---|---|---|
| KPI Number | Large number with label | Totals, rates, counts |
| Bar Chart | Vertical bars | Comparisons (enrollment by class, staff by department) |
| Line Chart | Line with data points | Trends over time |
| Area Chart | Filled line chart | Volume trends |
| Pie Chart | Circular segments | Proportions (gender split, fee type breakdown) |
| Donut Chart | Pie with center hole | Same as pie, different visual |
| Funnel Chart | Funnel stages | Pipeline stages (admissions) |
| Gauge | Circular gauge | Percentages (attendance rate, efficiency) |
| Data Table | Tabular data | Detailed breakdowns |
Data Sources
Widgets can pull data from these sources:
KPI Metrics
| Data Source | Description |
|---|---|
| Total Enrolled Students | Active student enrollment count |
| Today's Attendance Rate | Today's attendance percentage |
| Fee Collection (MTD) | Month-to-date fee collection amount |
| Total Outstanding | Outstanding invoice balance |
| Collection Efficiency | Collected / Invoiced percentage |
| Open Grievances | Unresolved grievance count |
| Library Issues | Currently issued (non-returned) books |
Entity Charts
| Data Source | Chart Type | Description |
|---|---|---|
| Enrolment by Class | Bar | Students per class |
| Staff by Department | Bar | Staff headcount per department |
| Outstanding by Ageing | Bar | Outstanding amounts in aging buckets (0-30d, 31-60d, etc.) |
| Attendance by Section | Bar | Attendance rate per section |
Saved Reports
Any saved report can be used as a widget data source. The report's data is fetched and rendered as a chart or table in the widget.
Pre-built Dashboard Templates
OptiCRM ships with 6 dashboard templates. Seed them by calling:
POST /api/admin/seed-dashboards| Template | Scope | Widgets |
|---|---|---|
| Admissions Overview | Institution | Enquiries, Conversions, Pipeline funnel, Source breakdown |
| Student Overview | Institution | Enrollment, Attendance, Class distribution, Gender split |
| Finance Dashboard | Role (Finance) | Collection, Outstanding, Overdue, Monthly trend |
| HR & Staff Dashboard | Role (HR) | Headcount, Teachers, Attendance, Department breakdown |
| Attendance Dashboard | Institution | Today's rate, Absent count, Weekly trend |
| Principal's Dashboard | Role (Principal) | Students, Staff, Attendance, Collection, Enrollment chart |
Managing Dashboards
Clone a Dashboard
In view mode, click Clone to create a copy. Useful for creating a personal variant of an institution dashboard.
Delete a Dashboard
In view mode, click Delete. Personal dashboards can only be deleted by their creator. Institution dashboards require admin access.
Set as Default
The first institution-scope dashboard is used as the default for all users who don't have a personal or role-scoped dashboard.
Tips
- Start with templates — seed the pre-built dashboards, then customize
- KPI widgets at the top — place KPI number widgets in the first row for a quick summary, charts below
- Use 4-column KPIs — KPI numbers look best at 3 or 4 columns wide (fits 3-4 per row)
- Use 6-column charts — charts need space; 6 columns (half width) or 12 columns (full width) work best
- Personal dashboards for power users — let teachers and finance officers create their own views
- Role-scoped for departments — create a Finance dashboard visible only to Finance Officers, an HR dashboard for HR staff