Files
zulip/templates/zerver/accounts_accept_terms.html
Rishi Gupta 902a7fbfe9 Change relative paths to absolute paths when we don't want the subdomain.
Changes relative path to an absolute path (that doesn't contain the
subdomain) for various links to
/create_realm, /api, /apps, /integrations, /hello, /terms, and the logged
out / (the Zulip in the upper left corner of portico)

I typically left links internal to the relevant pages (e.g. a link from
integrations.html to a subpage of integrations/) as relative links, and
changed external links from within the app to the absolute path (e.g. the
link to integrations from the gear menu).
2016-08-13 16:27:36 -07:00

61 lines
2.3 KiB
HTML

{% extends "zerver/portico_signup.html" %}
{#
Allow the user to accept a TOS, creating an email record of that fact.
Users only hit this page if they are coming from a migration or other update of the TOS;
the registration flow has its own (nearly identical) copy of the fields below in register.html.
#}
{% block for_you %}for {% if company_name %} {{company_name}} {% else %} __________ {% endif %} {% endblock %}
{% block portico_content %}
{% if special_message_template %}
{% include special_message_template %}
{% else %}
<div class="pitch">
<p>{{ _("There is a new terms of service.") }}</p>
<h3>{{ _("Accept the terms of service") }}</h3>
</div>
{% endif %}
<form method="post" class="form-horizontal" id="registration" action="{{ url('zerver.views.accounts_accept_terms') }}">
{{ csrf_input }}
<div class="control-group">
<label for="id_email" class="control-label">{{ _("Email") }}</label>
<div class="controls fakecontrol">
<p>{{ email }}</p>
</div>
</div>
<div class="control-group">
<div class="controls">
<label class="checkbox">
{#
This is somewhat subtle.
Checkboxes have a name and value, and when the checkbox is ticked, the form posts
with name=value. If the checkbox is unticked, the field just isn't present at all.
This is distinct from 'checked', which determines whether the checkbox appears
at all. (So, it's not symmetric to the code above.)
#}
<input id="id_terms" class="required" type="checkbox" name="terms"
{% if form.terms.value() %}checked="checked"{% endif %} />
{{ _("I agree to the") }} <a href="{{ external_uri_scheme }}{{ external_host }}/terms">{{ _("Terms of Service") }}</a>.
</label>
{% if form.terms.errors %}
{% for error in form.terms.errors %}
<div class="alert alert-error">{{ error }}</div>
{% endfor %}
{% endif %}
</div>
</div>
<br />
<div class="control-group">
<div class="controls">
<input type="submit" class="btn btn-primary" value="Enter" /><br />
<input type="hidden" name="next" value="{{ next }}" />
</div>
</div>
</form>
{% endblock %}