feat: scaffold a basic Django project structure

This commit is contained in:
sankalp committed 2025-10-29 10:59:58 +05:45
1 parent 1a2e50900d
commit b78ba6d308
33 files changed
+856

No files matched your search

View File
Whitespace-only changes.
View File
Whitespace-only changes.
+3
View File
@@ -0,0 +1,3 @@
from django.contrib import admin
# Register your models here.
+6
View File
@@ -0,0 +1,6 @@
from django.apps import AppConfig
class StoreConfig(AppConfig):
default_auto_field = "django.db.models.BigAutoField"
name = "store"
Whitespace-only changes.
+3
View File
@@ -0,0 +1,3 @@
from django.db import models
# Create your models here.
+16
View File
@@ -0,0 +1,16 @@
"""
API routes for store app.
"""
from rest_framework.routers import DefaultRouter
from . import views
# Create router instance
router = DefaultRouter()
# Register viewsets with router
# Example:
# router.register(r'store', views.StoreViewSet)
# Get URL patterns
urlpatterns = router.urls
+13
View File
@@ -0,0 +1,13 @@
"""
Serializers for store app.
"""
from rest_framework import serializers
# Add your serializers here
# Example:
# class StoreSerializer(serializers.ModelSerializer):
# class Meta:
# model = YourModel
# fields = '__all__'
+3
View File
@@ -0,0 +1,3 @@
from django.test import TestCase
# Create your tests here.
+9
View File
@@ -0,0 +1,9 @@
from django.urls import path
from . import views
app_name = "store"
urlpatterns = [
# Add your URL patterns here
# path('', views.index, name='index'),
]
+3
View File
@@ -0,0 +1,3 @@
from django.shortcuts import render
# Create your views here.