我在这里找到了一个django-oscar的主题。https:/github.comeggforsaleoscar-eggs-theme。但是没有任何文档可以安装它.我试着在oscartemplates目录下替换相应的文件,但它不工作。
确保你已经更新了OSCAR模板文件夹中的setting.py,因为文档中。
location = lambda x: os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', x)
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [
location('templates'), # templates directory of the project
],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
'django.template.context_processors.debug',
...
'oscar.core.context_processors.metadata',
],
},
},
]
https:/django-oscar.readthedocs.ioenlatesthowtohow_to_handle_statics.html。