Skip to content

feat: add verified student course ratings and reviews #18

Description

@Jidnyasa-P

Description

Students currently cannot share feedback about courses they have enrolled in. Add a course review system that allows enrolled students to submit one rating and review per course.

The feature should display an average rating and review count on course cards and course-detail pages.

Proposed Features

  • Allow only enrolled students to submit reviews.

  • Support ratings from 1 to 5 stars.

  • Allow an optional written review.

  • Permit one review per student per course.

  • Allow students to edit or delete their own review.

  • Display:

    • Average course rating
    • Total review count
    • Rating distribution
    • Recent reviews
  • Add sorting by:

    • Newest
    • Oldest
    • Highest rated
    • Lowest rated
  • Add pagination or Load More for reviews.

  • Show a verified-enrollment badge.

  • Add empty, loading, and error states.

  • Update rating summaries immediately after review changes.

Backend Requirements

Create a review model containing:

  • User ID
  • Course ID
  • Rating
  • Review text
  • Created timestamp
  • Updated timestamp

Add protected endpoints to:

  • Create a review
  • Retrieve course reviews
  • Update the current user’s review
  • Delete the current user’s review
  • Retrieve rating summary

Add a compound unique index on user ID and course ID.

Validate:

  • Rating range
  • Review length
  • Enrollment ownership
  • Course existence

Frontend Requirements

  • Add a rating summary to course cards and detail pages.
  • Add a review form for eligible students.
  • Add review cards with timestamps.
  • Add edit and delete controls for the review owner.
  • Add accessible star-rating controls.
  • Add responsive review layouts.

Acceptance Criteria

  • Only enrolled students can submit reviews.
  • Students can submit only one review per course.
  • Ratings accept values from 1 through 5.
  • Students can edit and delete only their own reviews.
  • Average rating updates correctly.
  • Rating distribution totals are correct.
  • Course cards display the rating summary.
  • Reviews support sorting and pagination.
  • Empty, loading, and error states are included.
  • The interface works on mobile and desktop.
  • Existing course and enrollment features remain unchanged.

@udaycodespace Kindly assign me this issue under ECSOC26

Metadata

Metadata

Assignees

Labels

ECSoC26Required label for a PR to be eligible for Sentinel scoringenhancementNew feature or improvement request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions