Skip to content

Backlog Issues for Anonymous Posting Feature (Feature 1) #81

@dkhalifa25

Description

@dkhalifa25

Issue 1: Extend Post Schema with isAnonymous Flag

Effort: 2h
Dependencies: None
Milestone: Sprint 1
Assignee: To be decided
Description:

  • Add isAnonymous boolean field to the post schema.
  • Ensure DB migration does not break existing posts.
  • Default isAnonymous = false unless explicitly set.

Acceptance Criteria:

  • Schema includes new isAnonymous flag.
  • Normal posts unaffected.
  • Test DB query returns posts with/without isAnonymous.

Issue 2: API Support for Anonymous Posts

Effort: 2-3h
Dependencies: Issue 1 (schema)
Milestone: Sprint 1
Assignee: To be decided
Description:

  • Update API to allow creating posts with isAnonymous = true.
  • When fetching posts, hide author info if isAnonymous is true (except for staff endpoints).
  • Ensure editing/quoting posts respects isAnonymous.

Acceptance Criteria:

  • Posting with isAnonymous = true hides author for regular users.
  • Staff-only API can reveal true author.
  • Attempting to override anonymity via API fails unless staff.

Issue 3: Role & Permission Enforcement

Effort: 1-2h
Dependencies: Issue 2 (API)
Milestone: Sprint 1
Assignee: To be decided
Description:

  • Restrict anonymous posting to student roles.
  • Ensure staff/admins can toggle visibility of author info.
  • Add audit log entry with true author ID for moderation.

Acceptance Criteria:

  • Students can submit anonymous posts.
  • Staff see “Anonymous Student” publicly, but can reveal author internally.
  • Audit log stores author for all anonymous posts.

Issue 4: Composer Checkbox for “Post Anonymously”

Effort: 1h
Dependencies: Issue 2 (API)
Milestone: Sprint 1
Assignee: To be decided
Description:

  • Add a checkbox labeled “Post Anonymously” in the post composer.
  • When checked, send isAnonymous = true in API request.

Acceptance Criteria:

  • Checkbox appears in composer.
  • Checked = post submitted anonymously, unchecked = normal post.
  • Works consistently on desktop and mobile views.

Issue 5: Anonymous Display on Posts

Effort: 2h
Dependencies: Issue 2 (API) + Issue 4 (UI)
Milestone: Sprint 2
Assignee: To be decided
Description:

  • Replace username/avatar with “Anonymous Student” for anonymous posts.
  • Add subtle indicator for staff (e.g., “posted anonymously – visible only to staff”).

Acceptance Criteria:

  • Anonymous posts show generic label instead of name/avatar.
  • Staff accounts see an extra indicator.
  • Consistent display in threads, notifications, and search results.

Issue 6: Consistency in Replies & Notifications

Effort: 1h
Dependencies: Issue 5 (display)
Milestone: Sprint 2
Assignee: To be decided
Description:

  • Ensure anonymity is preserved when posts are replied to, quoted, or appear in notifications.

Acceptance Criteria:

  • Replying to an anonymous post does not reveal the author.
  • Quoted anonymous posts show “Anonymous Student.”
  • Notifications for anonymous posts do not reveal the author.

Issue 7: Testing & Security Validation

Effort: 2-3h
Dependencies: Issues 1-6
Milestone: Sprint 2
Assignee: To be decided
Description:

  • Validate both anonymous and normal posting flows.
  • Confirm staff can view authorship while peers cannot.
  • Attempt to bypass anonymity with direct API calls.
  • Test editing/deleting/quoting behavior.

Acceptance Criteria:

  • Anonymous flow works end-to-end.
  • Staff-only visibility confirmed.
  • All edge cases handled correctly.
  • Security confirmed: no unauthorized role can reveal author.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions