diff --git a/ivatar/ivataraccount/views.py b/ivatar/ivataraccount/views.py index 0ec9d17..2baae49 100644 --- a/ivatar/ivataraccount/views.py +++ b/ivatar/ivataraccount/views.py @@ -57,6 +57,8 @@ class CreateView(SuccessMessageMixin, FormView): password=form.cleaned_data['password1']) if user is not None: login(self.request, user) + pref = UserPreference.objects.create(user_id=user.pk) + pref.save() return HttpResponseRedirect(reverse_lazy('profile')) else: return HttpResponseRedirect( diff --git a/templates/base.html b/templates/base.html index 4a3d3ba..a44ba01 100644 --- a/templates/base.html +++ b/templates/base.html @@ -2,11 +2,13 @@ {% load static %} {% load bootstrap4 %} {% load i18n %} -{% spaceless %}{% block bootstrap4_content %} + {% block bootstrap4_extra_head %} {% include 'header.html' %}