Overview
The Student Management page provides a comprehensive view of all students enrolled in your courses, with search functionality and enrollment details. Access it at/educator/students.
Page Layout
The students page features:Header Summary
Total enrollment count across all courses
Search Bar
Filter students by name or course title
Students Table
Detailed list of all enrollments
Responsive Design
Adapts to mobile, tablet, and desktop
Accessing Student Data
Navigate to the students page:Data Fetching
Student enrollment data is fetched on page load:Data is reversed (
.reverse()) to display the most recent enrollments first.Backend Implementation
The server provides detailed enrollment data:Only completed purchases are included. Pending or failed transactions don’t show up in the student list.
Enrollment Data Structure
Response Format
Field Descriptions
Student information from User model
Name of the course the student enrolled in
ISO 8601 timestamp of when the purchase was completed
Table Structure
The students table displays four columns:| Column | Description | Visible |
|---|---|---|
| # | Sequential row number (1, 2, 3…) | Hidden on mobile (sm:) |
| Student | Profile picture + name | Always visible |
| Course | Course title (truncated if long) | Always visible |
| Enrolled On | Formatted purchase date | Hidden on mobile (md:) |
Table Implementation
Search Functionality
Filter students in real-time by name or course:Search Implementation
Search Input
Search Behavior
- Name Search
- Course Search
- Combined
Search by student name (case-insensitive)
Search is performed client-side for instant results without API calls.
Date Formatting
Enrollment dates are formatted for readability:Localization
Using ‘en-IN’ formats dates for Indian audience:
- Day first (15 Jan)
- Abbreviated month names
- Full 4-digit year
- Indian Format (en-IN)
- US Format (en-US)
- ISO Format
Empty States
Graceful handling when no students are found:No Enrollments
No Search Results
Loading State
Skeleton UI while data is fetching:The loading state matches the layout of the actual content for a seamless transition.
Responsive Breakpoints
Mobile (below 640px)
- Only student name and course title visible
- Sequential numbers hidden
- Enrollment dates hidden
- Search bar full width
Tablet (640px-767px)
- Sequential numbers appear
- Enrollment dates still hidden
- Search bar maintains width
Desktop (≥768px)
- All columns visible
- Full table functionality
- Optimal spacing and layout
Duplicate Enrollments
How Duplicates Occur
A single student can appear multiple times if they:-
Enrolled in multiple courses
- Purchased the same course multiple times (rare, but possible if refund/re-purchase occurred)
Each row represents a purchase transaction, not a unique student. The same student can have multiple rows.
Total Count
The header displays the total enrollment count:Count vs. Unique Students
- Total Enrollments
- Unique Students
What’s displayed on this pageCount of all purchase records (may include same student multiple times)
Sorting and Ordering
Current Order
By default, students are sorted by most recent enrollment first:Custom Sorting (Not Implemented)
To add sortable columns:API Reference
Get Enrolled Students
Error Handling
Use Cases
Track Course Popularity
Track Course Popularity
Use the search to filter by course name and see how many students enrolled in each course:
- Search for “React Fundamentals”
- Count visible rows
- Compare with other courses
Monitor Recent Growth
Monitor Recent Growth
Since students are sorted by date (newest first), you can quickly see:
- How many enrollments in the last day/week
- Whether marketing campaigns are effective
- Enrollment spikes after course updates
Identify Repeat Students
Identify Repeat Students
Search for a student’s name to see all their enrollments:
- Type student name in search
- View all courses they’ve purchased
- Identify loyal/engaged students
Export Data (Future Enhancement)
Export Data (Future Enhancement)
Currently not available, but you could add:
- CSV export button
- Excel spreadsheet generation
- Email list extraction
- Revenue reports per student
Privacy Considerations
The student list contains personal information:- Full names
- Profile pictures
- Purchase history
Do not share student data publicly
Use HTTPS for all API requests
Respect student privacy in communications
Follow GDPR/data protection regulations
Future Enhancements
Potential features to add:Pagination
Handle large student lists (100+ enrollments)
Export to CSV
Download student data for analysis
Email Students
Send announcements or updates directly
Progress Tracking
See which students completed the course
Refund Management
Handle refund requests and disputes
Student Notes
Add private notes about specific students
Troubleshooting
Students not appearing
Students not appearing
Possible causes:
- Purchases are still pending (status ≠ ‘completed’)
- Database sync delay
- Filter/search hiding results
- Check Purchase model for status
- Clear search filter
- Refresh the page
Duplicate students showing
Duplicate students showing
This is expected behaviorEach row is a purchase record, not a unique student. Same student can appear multiple times if they bought multiple courses.To see unique students, you’d need to implement deduplication logic.
Search not working
Search not working
Check:
- Search is case-insensitive, but must match part of name/course
- Ensure no typos in search term
- Try searching just first name or partial course title
Dates showing incorrectly
Dates showing incorrectly
Possible causes:
- Timezone differences
- Browser locale settings
toLocaleDateString locale parameter.