Newer
Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
{% extends 'portal/public/base.html' %}
{% load i18n %}
{% block login %}{% endblock %}
{% block main_content %}
<div class="container" style="min-height: 400px;">
{% if form.errors or next %}
<div class="row">
<div class="col-sm-8 mx-auto">
{% if form.errors %}
{% include 'portal/widgets/alert_widget.html' with msg=_("Your username and password didn't match. Please try again.") %}
{% elif next %}
{% if user.is_authenticated %}
{% include 'portal/widgets/alert_widget.html' with msg=_("Your account doesn't have access to this page.<br />To proceed, please login with an account that has access.") %}
{% else %}
{% include 'portal/widgets/alert_widget.html' with msg=_("Please login to see this page.") %}
{% endif %}
{% endif %}
</div>
</div>
{% endif %}
<div class="form-signin">
<form role="form" method="post" action="">
{% csrf_token %}
<h2 class="form-signin-heading">{% trans 'Please sign in' %}</h2>
<input type="text" class="form-control" name="username" placeholder="{% trans 'Login' %}" required autofocus />
<input type="password" class="form-control" name="password" placeholder="{% trans 'Password' %}" required />
<button class="btn btn-lg btn-primary btn-block" type="submit">
{% trans 'Sign in' %}
</button>
<input type="hidden" name="next" value="{{ next }}" />
</form>
<div id="forgotten-password">
<a href="{% url 'password_reset' %}" class="text-muted">
<em>{% trans 'Forgot your password' %}?</em>
</a>
</div>
Jonathan Seguin
committed
{% if azuread_oauth %}
Jonathan Seguin
committed
<a class="btn btn-info mt-2" href="{% url 'social:begin' 'azuread-tenant-oauth2' %}"><i class="fa fa-university mr-2"></i>{% trans "Login with University of Montreal account" %}</a>