在终端输入
python manage.py startapp XXX(自己的app名字)
如下图所示
然后在settings.py中找到INSTALLED_APPS模块输入刚新建的app,如下所示
INSTALLED_APPS = [
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'books'
]