diff --git a/rcamp/accounts/models.py b/rcamp/accounts/models.py index 241d268..19d3b39 100644 --- a/rcamp/accounts/models.py +++ b/rcamp/accounts/models.py @@ -219,7 +219,7 @@ class Meta: full_name = ldap_fields.CharField(db_column='cn') email = ldap_fields.CharField(db_column='mail') # posixAccount - username = ldap_fields.CharField(db_column='uid', primary_key=True) + username = ldap_fields.CharField(db_column='uid') # ldap specific modified_date = ldap_fields.DateTimeField(db_column='modifytimestamp',blank=True) diff --git a/rcamp/rcamp/settings/main.py b/rcamp/rcamp/settings/main.py index 48f7061..8aba66c 100644 --- a/rcamp/rcamp/settings/main.py +++ b/rcamp/rcamp/settings/main.py @@ -11,6 +11,9 @@ hosts = os.environ.get('RCAMP_ALLOWEDHOSTS') ALLOWED_HOSTS = hosts.split(',') +CSRF_TRUSTED_ORIGINS = [ + "https://rcamp.rc.colorado.edu", +] INSTALLED_APPS = [ 'django.contrib.admin', @@ -71,6 +74,7 @@ LOGIN_REDIRECT_URL = '/' +LOGOUT_REDIRECT_URL = "/login" # Internationalization # https://docs.djangoproject.com/en/1.8/topics/i18n/ diff --git a/rcamp/rcamp/templates/base.html b/rcamp/rcamp/templates/base.html index b8ade10..01579fc 100644 --- a/rcamp/rcamp/templates/base.html +++ b/rcamp/rcamp/templates/base.html @@ -42,7 +42,12 @@ {% if request.user.is_authenticated %}