Shreya P taking over for Abhiram Bylahalli Jagadish – Display List of Finished Tasks Reported by Students#1799
Conversation
…l refs, resolve eslint warnings
…to education task model
|
Hi Abhiram, I have tested this PR locally, the frontend works as required but in the backend - i was able to identify few issues.
a) when i give status as graded and a student id it shows empty string b) when i give status as pending/graded i get data which is both graded and pending Note: Have updated my comment on Dec 24th and the issues still persist |
sayali-2308
left a comment
There was a problem hiding this comment.
Backend running on: http://localhost:4500
Branch: feature/abhiram-educator-task-submissions
Testing tool: Postman
Database: MongoDB with education portal test data
Date: February 3, 2026
Summary:
Educator Task Submissions API endpoint fully functional and tested. GET /api/educationportal/educator/task-submissions successfully retrieves student task submissions with all required fields (studentName, studentEmail, taskName, taskType, submissionLinks, status, submittedAt, assignedAt, dueAt, grade, lessonPlanId, lessonPlanTitle). All query parameter filters working correctly (status: completed/graded, studentId). Status badges properly mapped (completed → Pending Review, graded → Graded). Multiple submission links supported. Population logic working for student and lesson plan details. Response structure clean and matches API requirements. Ready for frontend integration.
Overall: All requirements met, filters working as expected, proper data population and formatting. Ready to merge.
…missions endpoint
|
ShreyaMP1999
left a comment
There was a problem hiding this comment.
I reviewed the existing implementation for the Educator Task Submissions feature and made a few necessary improvements to both the frontend and backend to ensure stability and consistency. On the frontend, I fixed duplicate rendering issues, ensured stable React keys for submission cards, normalized status handling to align with backend responses, and added safer date handling to avoid invalid comparisons. I also improved edge-case handling for student name initials and ensured better resilience in UI rendering. On the backend, I verified the response structure and filtering logic to confirm it aligns correctly with the frontend requirements.
I tested the complete flow end-to-end, including API validation in Postman, UI behavior in the browser, and responsiveness using Safari mobile simulator. All core functionalities such as filtering, grouping, status display, and late submission detection are working as expected. Screenshots and testing evidence have been uploaded to the Dropbox link for reference.
|
I have tested and reviewed this PR locally, also posted comments and screenshots on the frontend for PR #4207 |
|
















Description
This PR implements the backend endpoint for educator task submissions as required for the "Display List of Finished Tasks Reported by Students" feature. Educators can view student task completions and uploads in a dynamic task list, supporting filtering by status, student, and course. The response includes student name, task name, submission link, status badge/tag, and submitted date. All controller and model logic is updated for proper data population, filter handling, and code quality compliance.

Related PR:
Frontend: OneCommunityGlobal/HighestGoodNetworkApp#4207
Implements:
/api/educationportal/educator/task-submissionsstatus,studentId,courseIdfor filteringstudentName,task,submissionLink,status,submittedAtMain changes explained
/api/educationportal/educator/task-submissionsfetches completed and graded student submissionsHow to test
Prerequisites:
git checkout feature/abhiram-educator-task-submissionsrm -rf node_modules package-lock.json && npm cache clean --force && npm installnpm run devAPI Testing Steps:
Note: All requests must use the full path
/api/educationportal/educator/task-submissions.http://localhost:4500/api/educationportal/educator/task-submissionsWith query params as needed:
statusstudentIdcourseIdExpected:
Note: Screenshots above show visual examples. Sample JSON outputs below use generic placeholder data and do not reflect real user information.
Test Cases for Educator Task Submissions API
Prerequisites
Test 1: Basic Request (No Filters)
Request:
Authorization: BearerContent-Type: application/jsonVerify:
studentName,studentEmail,taskName,taskType,submissionLinks,status,submittedAt,assignedAt,dueAt,grade,feedback,lessonPlanIdSample Output:
[ { "studentName": "<student-name>", "studentEmail": "<student-email>", "taskName": "<task-name>", "taskType": "<task-type>", "submissionLinks": ["<submission-url>"], "status": "<status>", "submittedAt": "<timestamp>", "assignedAt": "<timestamp>", "dueAt": "<timestamp>", "grade": "<grade-or-null>", "feedback": "<feedback-or-null>", "lessonPlanId": "<lesson-plan-id>" } ]Test 2: Filter by Status Only
Request:
Authorization: BearerVerify:
completed(should show as "Pending Review" in response)Sample Output:
[ { "studentName": "<student-name>", "studentEmail": "<student-email>", "taskName": "<task-name>", "taskType": "<task-type>", "submissionLinks": ["<submission-url>"], "status": "Pending Review", "submittedAt": "<timestamp>", "assignedAt": "<timestamp>", "dueAt": "<timestamp>", "grade": null, "feedback": null, "lessonPlanId": "<lesson-plan-id>" } ]Test 3: Filter by Student
Request:
Authorization: BearerVerify:
→ Only graded tasks for that student
Test 4: Missing/Invalid Auth Token
Request:
Verify:
This implementation completes all listed backend requirements for the educator dashboard task list feature.