Skip to content

Implement Projects CRUD Functionality Based on Prisma Models #6

@adgator101

Description

@adgator101

Overview

Implement Create, Read, Update, and Delete (CRUD) functionality for Projects using the Prisma models defined in prisma/schema/auth.prisma. This should cover all relevant models and relations, including contributors, tags, and project contributors.

Relevant Prisma Models

  • Project: Contains fields such as id, name, githubLink, demoLink, tagId, tech_stack, description, thumbnailUrl, createdAt, updatedAt, and relations to Tag, Contributor, and ProjectContributors.
  • Tag: Used for project categorization. Projects reference tags via tagId.
  • Contributor: Represents individuals who contribute to projects. Projects relate to contributors both directly and through the ProjectContributors join table.
  • ProjectContributors: Join table for many-to-many relationship between projects and contributors.

Tasks

  • Implement endpoint to create a new project, including assignment of tags and contributors
  • Implement endpoint to fetch project(s) with tags and contributors
  • Implement endpoint to update project details, including contributors and tags
  • Implement endpoint to delete a project (and related contributors in join table)
  • Add validation and error handling for all endpoints
  • Write unit and integration tests for all CRUD operations
  • Update API documentation for new endpoints

Acceptance Criteria

  • All CRUD endpoints for Projects function as intended
  • Projects are stored and queried using the Prisma models
  • Contributors and tags can be assigned and updated for projects
  • Tests cover all CRUD scenarios
  • Documentation is current and accurate

Reference

See the Project, Tag, Contributor, and ProjectContributors models in prisma/schema/auth.prisma.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request
No fields configured for Feature.

Projects

Status

In review

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions