[Answer]-And again Django can't find template (TemplateDoesNotExist)

1👍

from Upgrading templates to Django 1.8

TEMPLATES = [
    {
        'BACKEND': 'django.template.backends.django.DjangoTemplates',
        'DIRS': [
            **Your TEMPLATE_PATH**,
        ],
        'APP_DIRS': True,
        'OPTIONS': {
            'context_processors': [
                'django.template.context_processors.debug',
                'django.template.context_processors.request',
                'django.contrib.auth.context_processors.auth',
                'django.contrib.messages.context_processors.messages',
            ],
        },
    },
]
👤Alan

0👍

Please double check your template file path and file name. Maybe you can provide file structure of your django folder.

Here is my settings.py about template folder:

TEMPLATE_DIRS = (
    os.path.join(BASE_DIR,'templates'),
    os.path.join(BASE_DIR,'templates','OMS'),
    os.path.join(BASE_DIR,'templates','CRM'),
    os.path.join(BASE_DIR,'templates','PMS'),
    os.path.join(BASE_DIR,'templates','BPS'),
)

and my template structure:

base_template.html  PMS
BPS                 CRM                 OMS

Leave a comment