在django-oscar中安装eggs主题。

问题描述 投票:2回答:1

我在这里找到了一个django-oscar的主题。https:/github.comeggforsaleoscar-eggs-theme。但是没有任何文档可以安装它.我试着在oscartemplates目录下替换相应的文件,但它不工作。

python themes django-oscar
1个回答
0
投票

确保你已经更新了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。

© www.soinside.com 2019 - 2024. All rights reserved.