1、注册app
INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', #注册app 'projects' ]
2、更改语言和时间地区
# 更改语言和时间地区 LANGUAGE_CODE = 'zh-hans' TIME_ZONE = 'Asia/Shanghai'