That project is example of simple backend for notes. In this project realised simple CRUD for models with permissions. For example user can work and see only own notes, but admin every note. User can see every category, but edit, delete, update only own. There is used JWT for auth users. User can create account by username and email. Admin have full CRUD for any model by DRF.
- /api/logic/note/ - viewset for note with full CRUD, have permissions, writed in description
- /api/logic/category/ - viewset for category with full CRUD, have permissions, writed in description
- /api/accounts/register/ - registration
- /api/accounts/users/ - CRUD for user account, can access only admin
- /api/token/ - get jwt token
- /api/token/refresh - refresh jwt
For this project was frited a few tests using pytest and django modelfactory. For tests created a fake database with fake objects agter testing database is deleting. Percentage of coverage 90%
Install docker
and docker-compose
.
Create .env.dev
like .env.example
. Set the settings.
docker compose up