diff --git a/comprehensive/cms/templates/register.html b/comprehensive/cms/templates/register.html index 148e7f2..e4ade11 100644 --- a/comprehensive/cms/templates/register.html +++ b/comprehensive/cms/templates/register.html @@ -1,8 +1,14 @@ +<%namespace name='static' file='/static_content.html'/> <%inherit file="base.html" /> <%def name="online_help_token()"><% return "register" %> <%! +import third_party_auth from django.utils.translation import ugettext as _ from django.core.urlresolvers import reverse +from openedx.core.djangolib.js_utils import dump_js_escaped_json +from third_party_auth import provider, pipeline + +providers = provider.Registry.displayed_for_login() %> <%block name="title">${_("Sign Up")} @@ -21,6 +27,38 @@ from django.core.urlresolvers import reverse
+ % if third_party_auth.is_enabled() and providers and not running_pipeline: + + + % if not static.get_value('ONLY_THIRD_PARTY_AUTH', settings.FEATURES.get('ONLY_THIRD_PARTY_AUTH', False)): +
+

+ ${_("or create a new one here")} +

+
+ % endif + % endif + + % if not static.get_value('ONLY_THIRD_PARTY_AUTH', settings.FEATURES.get('ONLY_THIRD_PARTY_AUTH', False)) or running_pipeline:
@@ -31,25 +69,26 @@ from django.core.urlresolvers import reverse
  • ## Translators: This is the placeholder text for a field that requests an email address. - +
  • ## Translators: This is the placeholder text for a field that requests the user's full name. - +
  • ## Translators: This is the placeholder text for a field that asks the user to pick a username - + ${_("This will be used in public discussions with your courses and in our edX101 support forums")}
  • -
  • +
  • +
  • @@ -65,8 +104,10 @@ from django.core.urlresolvers import reverse
  • - - I agree to the Terms of Service + +
  • @@ -77,6 +118,8 @@ from django.core.urlresolvers import reverse + % endif +
    @@ -108,6 +151,18 @@ from django.core.urlresolvers import reverse <%block name="requirejs"> require(["js/factories/register"], function (RegisterFactory) { - RegisterFactory(); + var options = { + autoSubmitRegForm: ${selected_provider and selected_provider.skip_registration_form | n, dump_js_escaped_json} + } + RegisterFactory(options); }); + +<%block name="jsextra"> + + \ No newline at end of file diff --git a/courses/cms/templates/register.html b/courses/cms/templates/register.html index 148e7f2..e4ade11 100644 --- a/courses/cms/templates/register.html +++ b/courses/cms/templates/register.html @@ -1,8 +1,14 @@ +<%namespace name='static' file='/static_content.html'/> <%inherit file="base.html" /> <%def name="online_help_token()"><% return "register" %> <%! +import third_party_auth from django.utils.translation import ugettext as _ from django.core.urlresolvers import reverse +from openedx.core.djangolib.js_utils import dump_js_escaped_json +from third_party_auth import provider, pipeline + +providers = provider.Registry.displayed_for_login() %> <%block name="title">${_("Sign Up")} @@ -21,6 +27,38 @@ from django.core.urlresolvers import reverse
    + % if third_party_auth.is_enabled() and providers and not running_pipeline: + + + % if not static.get_value('ONLY_THIRD_PARTY_AUTH', settings.FEATURES.get('ONLY_THIRD_PARTY_AUTH', False)): +
    +

    + ${_("or create a new one here")} +

    +
    + % endif + % endif + + % if not static.get_value('ONLY_THIRD_PARTY_AUTH', settings.FEATURES.get('ONLY_THIRD_PARTY_AUTH', False)) or running_pipeline:
    @@ -31,25 +69,26 @@ from django.core.urlresolvers import reverse
  • ## Translators: This is the placeholder text for a field that requests an email address. - +
  • ## Translators: This is the placeholder text for a field that requests the user's full name. - +
  • ## Translators: This is the placeholder text for a field that asks the user to pick a username - + ${_("This will be used in public discussions with your courses and in our edX101 support forums")}
  • -
  • +
  • +
  • @@ -65,8 +104,10 @@ from django.core.urlresolvers import reverse
  • - - I agree to the Terms of Service + +
  • @@ -77,6 +118,8 @@ from django.core.urlresolvers import reverse + % endif +
    @@ -108,6 +151,18 @@ from django.core.urlresolvers import reverse <%block name="requirejs"> require(["js/factories/register"], function (RegisterFactory) { - RegisterFactory(); + var options = { + autoSubmitRegForm: ${selected_provider and selected_provider.skip_registration_form | n, dump_js_escaped_json} + } + RegisterFactory(options); }); + +<%block name="jsextra"> + + \ No newline at end of file