Skip to content

feat(faq): add satisfaction rating with admin visibility - #203

Open
kshethragna-mikkineni wants to merge 7 commits into
vicharanashala:mainfrom
kshethragna-mikkineni:feature/faq-satisfaction
Open

feat(faq): add satisfaction rating with admin visibility#203
kshethragna-mikkineni wants to merge 7 commits into
vicharanashala:mainfrom
kshethragna-mikkineni:feature/faq-satisfaction

Conversation

@kshethragna-mikkineni

Copy link
Copy Markdown

What changed

Adds a FAQ satisfaction rating system: users (guest or authenticated) rate
an FAQ's helpfulness on a 1–5 scale, ratings aggregate into satisfactionAvg
and satisfactionCount on the FAQ, and admins can view and sort by this
average in the admin FAQ table. Built by a 5-person team across the data
model, backend API, frontend rating UI, and admin surface.

Related issue

Closes #202

Type of change

  • Feature

Area affected

  • Backend (Express / Mongoose)
  • Frontend (React / Vite)
  • Admin / Train tab (/admin/*)
  • Docs

CI verification

  • cd apps/backend && npx tsc --noEmit exits 0
  • cd apps/backend && npx vitest run — all tests pass
  • cd apps/frontend && npx tsc --noEmit exits 0
  • cd apps/frontend && npx vitest run — all tests pass
  • pnpm run lint — 0 errors (152 warnings is the baseline)
  • GitHub Actions green on the merge commit (CI, CodeQL, Build & Deploy)
  • Tested with a real API hit or browser interaction if behaviour changed
  • Tests added or updated for the change
  • Single logical change — unrelated fixes noted in description, not fixed here
  • Docs updated if route / API / env var / pipeline behaviour changed
  • Rebased onto main, no merge commits

Notes for reviewer

This is a draft PR, opened early per repo convention, from a shared
branch with 5 contributors. Current status:

  • Done: data model + aggregate helper, backend API (GET/POST satisfaction),
    frontend rating slider, admin sortable satisfactionAvg column
  • In progress: backend Vitest tests, Playwright e2e test,
    docs/reference/openapi.yaml and docs/reference/database-schema.md updates
  • Admin-side sorting is client-side only — no server index exists yet on
    satisfactionAvg; flagged as a possible follow-up, not blocking.
  • Will request review and move out of draft once the above are complete and
    all CI verification boxes above are checked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

FAQ Satisfaction Rating — 1-5 rating with admin visibility

5 participants