Reorganize api files

This commit is contained in:
saqibur 2022-04-14 18:50:07 +06:00
parent a5e9ee1357
commit 07e27b8d1e
7 changed files with 10 additions and 17 deletions

View File

@ -125,6 +125,16 @@ within each relevant app, sometimes it makes more sense to build an app
specifically for the API. This is where all the serializers, renderers, and views specifically for the API. This is where all the serializers, renderers, and views
are placed. Therefore, the name of the app should reflect its API version are placed. Therefore, the name of the app should reflect its API version
##### `api-versioning`
It might often be necessary to support multiple versions of an API throughout the lifetime of a project. Therefore, we're adding in support right from the start.
For different API versions, we're assuming the following will change:
- Serializers
- Views
- URLs
- Services
Whereas the `model`s will be shared.
### `config` ### `config`
* Contains project configuration files, including the primary URL file * Contains project configuration files, including the primary URL file

View File

@ -1,3 +0,0 @@
from django.contrib import admin
# Register your models here.

View File

@ -1,3 +0,0 @@
from django.test import TestCase
# Create your tests here.

View File

@ -1,2 +0,0 @@
APIView
def does one thing

View File

@ -1,6 +0,0 @@
from django.apps import AppConfig
class AppConfig(AppConfig):
default_auto_field = 'django.db.models.BigAutoField'
name = 'app'

View File

@ -1,3 +0,0 @@
from django.db import models
# Create your models here.