Create a Django Application and Add app to the Settings - SethuGopalan/ebdjangoVR GitHub Wiki
To create the app, run the following command:
python manage.py startapp Tech_projects
This will create another directory called Tech_projects with several files:
-
init.py tells Python to treat the directory as a Python package.
-
admin.py contains settings for the Django admin pages.
-
apps.py contains settings for the application configuration.
-
models.py contains a series of classes that Django’s ORM converts to database tables. tests.py contains test classes.
-
views.py contains functions and classes that handle what data is displayed in the HTML templates.
In order to hook up our app, we need to add it into INSTALLED_APPS in settings.py:
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'Tech_projects',
]