Commit 7914a009 by Saleem Latif

Show Enterprise Logistration for coupon users

parent c21b3c8f
...@@ -3189,6 +3189,7 @@ ENTERPRISE_EXCLUDED_REGISTRATION_FIELDS = { ...@@ -3189,6 +3189,7 @@ ENTERPRISE_EXCLUDED_REGISTRATION_FIELDS = {
'year_of_birth', 'year_of_birth',
'mailing_address', 'mailing_address',
} }
ENTERPRISE_CUSTOMER_COOKIE_NAME = 'enterprise_customer_uuid'
############## Settings for Course Enrollment Modes ###################### ############## Settings for Course Enrollment Modes ######################
COURSE_ENROLLMENT_MODES = { COURSE_ENROLLMENT_MODES = {
......
...@@ -248,7 +248,7 @@ def enterprise_customer_for_request(request, tpa_hint=None): ...@@ -248,7 +248,7 @@ def enterprise_customer_for_request(request, tpa_hint=None):
except EnterpriseCustomer.DoesNotExist: except EnterpriseCustomer.DoesNotExist:
pass pass
ec_uuid = request.GET.get('enterprise_customer') ec_uuid = request.GET.get('enterprise_customer') or request.COOKIES.get(settings.ENTERPRISE_CUSTOMER_COOKIE_NAME)
if not ec and ec_uuid: if not ec and ec_uuid:
try: try:
ec = EnterpriseCustomer.objects.get(uuid=ec_uuid) ec = EnterpriseCustomer.objects.get(uuid=ec_uuid)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment