Skip to content

victor0198ebs/drf-blog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple DRF blog example and test

Setup

  1. In /config/ copy development_sample.py as development.py
  2. Database is SQLite, local, and execute python manage.py migrate
  3. Start the project
  4. Register a user in /users/register/ endpoint
  5. Login with registered credentials in /users/token/ endpoint
  6. In swagger click "Authorize" button and type Bearer <access token from response>
  7. Enjoy other endpoints

Tasks

  1. Add in Blog model boolean field enabled
  2. Show in admin blog list the real blog name and status (enabled/disabled): http://prntscr.com/nnsoa8
  3. Make an endpoint for create a blog post (similar as register endpoint)

Config

For run project in another ENV:

DJANGO_ENV = production

default value is development

Create a new app

mkdir -p apps/name_of_app
python manage.py startapp name_of_app apps/name_of_app

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published