Skip to content

USER STORY: Create Projects API #19

@blahosyl

Description

@blahosyl

As an Admin,

I want to create a Projects app in the backend,

so that user's projects can be handled appropriately

Acceptance Criteria

  1. A Projects API exists in the backend with full CRUD functionalities
  2. Only logged-in users can manage their own project resources

Tasks

  • create projects app
    • add projects app to INSTALLED_APPS in settings.py
  • create Projects model
    • makemigrations
    • migrate
  • create projects views
    • list view
    • detail view
  • create projects serializers
    • list serializer
    • detail serializer
  • restrict project resource
  • create IsOwnerOrReadOnly permission (if not created yet)
  • add is_owner field to serializer
  • adjust project/views.py to restrict editing a profile to the profile owner
  • automated tests
    • test project list view
    • test project detail view

Manual testing

  • project list
    • list of instances visible to all users
    • logged-in users can create new instance
    • visitors (not logged in) cannot create instances
  • project detail
    • existing instance is visible to all users
    • putting the wrong instance ID in the URL gives a 404 error
    • logged-in users can edit their own instance
    • logged-in users can delete their own instance
    • logged-in users cannot edit other users' instances
    • logged-in users cannot delete other users' instances
    • visitors (not logged in) cannot edit instances
    • visitors (not logged in) cannot delete instances

Metadata

Metadata

Assignees

Labels

Projects

Status

Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions