Reputation: 651
I copied the django-allauth account and socialaccount templates under
my_django_project/templates/account
my_django_project/templates/socialaccount
respectively. Allauth successfully reads the overwritten account templates but it does not read
templates/socialaccount/snippets/provider_list.html
my settings.py looks like this:
TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [os.path.join(BASE_DIR, 'templates')],
'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',
],
},
},
]
The socialaccount templates are called in login.html with an include tag:
{% include "socialaccount/snippets/provider_list.html" %}
it looks likethe {% url %} tag works but {% include %} calls the original package template. How can I force {% include %} to look into the templates folder?
Upvotes: 1
Views: 92
Reputation: 651
Actually it has always been workin. The problem is that provider_list.html has an if condition
{% if provider.id == "openid" %}
and since this is false ( i still don't know why) the changed that I made withing the if condition don't appear.
Upvotes: 1