Skip to content

Backend Preparation for Assignment & Quiz Creation IntegrationΒ #164

@Jose-Alarcon1

Description

@Jose-Alarcon1

Backend Preparation for Assignment & Quiz Creation Integration

Is your feature request related to a problem?

πŸ”Ή Frontend for creating/editing assignments and quizzes is complete. However, backend APIs and serializers need to be verified and prepped to ensure full compatibility with the current React JSX interface.

Describe the solution you'd like

βœ… We need fully functional and integrated backend endpoints that support the following:

  • Creating, retrieving, updating, and deleting:
    • Assignments
    • Quizzes linked to assignments
    • Questions (SA/MC)
    • Choices for MC questions
    • Solutions for both MC and SA types
  • Consistent endpoint structure using assignment_id, quiz_id, and question_id as route parameters
  • JSON validation in serializers for required fields
  • Error handling for missing or invalid payloads
  • Integration of permissions (admin/tutor only where needed)

Tasks Breakdown

  • Confirm all endpoint routes from urls.py are active and functional
  • Validate all views return consistent response structures (status, data, error)
  • Update serializers if needed to support nested object creation or validation
  • Ensure choices are only accepted for MC questions and short_answer_text for SA
  • Confirm all routes align with frontend fetch/post expectations
  • Add necessary unit tests for:
    • Assignment creation
    • Quiz creation under assignment
    • Adding questions (SA/MC)
    • Handling MC choices correctly
    • Handling SA solutions cleanly

Additional Context

  • πŸ“Œ Frontend: AssignmentCreate.jsx (React)
  • πŸ“Œ Backend:
    • Models: Assignment, Quiz, Question, Choice, Solution
    • Views: AssignmentDetailView, QuizListCreateView, etc.
    • Serializers: AssignmentSerializer, QuestionSerializer, etc.
  • πŸ“Œ Permissions: IsAdminOrTutor enforced for all create/update/delete endpoints

Priority & Impact

⚑ High – This feature blocks full quiz/assignment UI functionality and frontend/backend testing.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions