Add registration and login templates plus UI stuff, moderation
This commit is contained in:
10
ojusomap/templates/400.html
Normal file
10
ojusomap/templates/400.html
Normal file
@ -0,0 +1,10 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Title</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
</body>
|
||||
</html>
|
9
ojusomap/templates/403.html
Normal file
9
ojusomap/templates/403.html
Normal file
@ -0,0 +1,9 @@
|
||||
{% extends 'base_page.html' %}
|
||||
|
||||
{% block title %}
|
||||
Shucks.
|
||||
{% endblock %}
|
||||
|
||||
{% block description %}
|
||||
Looks like you're not supposed to be here.
|
||||
{% endblock %}
|
9
ojusomap/templates/404.html
Normal file
9
ojusomap/templates/404.html
Normal file
@ -0,0 +1,9 @@
|
||||
{% extends 'base_page.html' %}
|
||||
|
||||
{% block title %}
|
||||
Shucks.
|
||||
{% endblock %}
|
||||
|
||||
{% block description %}
|
||||
You've taken a wrong turn and we can't find the page you're looking for.
|
||||
{% endblock %}
|
9
ojusomap/templates/500.html
Normal file
9
ojusomap/templates/500.html
Normal file
@ -0,0 +1,9 @@
|
||||
{% extends 'base_page.html' %}
|
||||
|
||||
{% block title %}
|
||||
Shucks.
|
||||
{% endblock %}
|
||||
|
||||
{% block description %}
|
||||
An unknown server error occurred. Sorry about that.
|
||||
{% endblock %}
|
66
ojusomap/templates/base.html
Normal file
66
ojusomap/templates/base.html
Normal file
@ -0,0 +1,66 @@
|
||||
{% spaceless %}
|
||||
{% load i18n %}
|
||||
{% load leaflet_tags %}
|
||||
{% load static %}
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<!-- Required meta tags -->
|
||||
<meta charset="utf-8">
|
||||
<title>{% block page_title %}Ojuso{% endblock %}</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
|
||||
<script src="{% static 'map/bundle.js'%}"></script>
|
||||
|
||||
{# Additional Stylesheets #}
|
||||
{% block stylesheets %}
|
||||
<style>
|
||||
.navbar-brand {padding: 5px 15px;}
|
||||
.navbar-brand > img {height: 40px;}
|
||||
</style>
|
||||
{% endblock %}
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<nav class="navbar navbar-expand-lg navbar-light bg-light">
|
||||
<a class="navbar-brand" href="{% url 'index' %}">
|
||||
<img src="{% static 'map/images/ojuso-logo-black.png' %}" height="40px"/>
|
||||
</a>
|
||||
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
|
||||
<span class="navbar-toggler-icon"></span>
|
||||
</button>
|
||||
<div class="collapse navbar-collapse" id="navbarNav">
|
||||
<ul class="navbar-nav">
|
||||
<li class="nav-item active">
|
||||
<a class="nav-link" href="#">Map <span class="sr-only">(current)</span></a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="#">Policy</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="#">Contact</a>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" href="#">FAQ</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
{% if user.is_authenticated %}
|
||||
<span>{{user}}</span>
|
||||
<a class="btn btn-primary" href={% url 'auth_logout' %}>Logout</a>
|
||||
{% else %}
|
||||
<a style="margin: 5px;" class="btn btn-primary" href={% url 'auth_login' %}>Login</a>
|
||||
<a style="margin: 5px;" class="btn btn-info" href={% url 'registration_register' %}>Register</a>
|
||||
{% endif %}
|
||||
</nav>
|
||||
|
||||
{% block body %}{% endblock %}
|
||||
</body>
|
||||
|
||||
{# CDN Javascript #}
|
||||
<script src="//code.jquery.com/jquery-3.2.1.min.js"
|
||||
integrity="sha384-xBuQ/xzmlsLoJpyjoggmTEz8OWUFM0/RC5BsqQBDX2v5cMvDHcMakNTNrHIW2I5f"
|
||||
crossorigin="anonymous">
|
||||
</script>
|
||||
{% block scripts %}{% endblock %}
|
||||
</html>
|
||||
{% endspaceless %}
|
27
ojusomap/templates/base_page.html
Normal file
27
ojusomap/templates/base_page.html
Normal file
@ -0,0 +1,27 @@
|
||||
{% extends "base.html" %}
|
||||
|
||||
{% block stylesheets %}
|
||||
{{ block.super }}
|
||||
<style>
|
||||
|
||||
.page-lead {
|
||||
padding: 40px 15px;
|
||||
text-align: center;
|
||||
}
|
||||
</style>
|
||||
{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
<div class="container">
|
||||
|
||||
<div class="page-lead">
|
||||
<h1 class="text-center">{% block title %}{% endblock %}</h1>
|
||||
<p class="lead text-center">{% block description %}{% endblock %}</p>
|
||||
</div>
|
||||
|
||||
{% block content %}
|
||||
{% endblock %}
|
||||
|
||||
</div><!-- /.container -->
|
||||
{% endblock %}
|
25
ojusomap/templates/base_with_jumbo.html
Normal file
25
ojusomap/templates/base_with_jumbo.html
Normal file
@ -0,0 +1,25 @@
|
||||
{% extends "base.html" %}
|
||||
|
||||
{% block stylesheets %}
|
||||
{{ block.super }}
|
||||
<style>
|
||||
.jumbo {
|
||||
height: calc(100% - 64px);
|
||||
width: 100%;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
}
|
||||
</style>
|
||||
{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
|
||||
<div class="jumbo">
|
||||
|
||||
{% block content %}
|
||||
{% endblock %}
|
||||
|
||||
</div><!-- /.container -->
|
||||
{% endblock %}
|
1
ojusomap/templates/registration/activate.html
Normal file
1
ojusomap/templates/registration/activate.html
Normal file
@ -0,0 +1 @@
|
||||
{% extends 'base_page.html' %}
|
1
ojusomap/templates/registration/activation_complete.html
Normal file
1
ojusomap/templates/registration/activation_complete.html
Normal file
@ -0,0 +1 @@
|
||||
{% extends 'base_page.html' %}
|
10
ojusomap/templates/registration/activation_email.html
Normal file
10
ojusomap/templates/registration/activation_email.html
Normal file
@ -0,0 +1,10 @@
|
||||
{% extends 'base_email.html' %}
|
||||
{% block content %}
|
||||
<div align="left">
|
||||
{{user}},<br><br>
|
||||
To activate your account and log in, <a href="https://animalrightsmap.org{% url 'registration_activate' activation_key %}">click here</a>.<br>
|
||||
This link will expire in 7 days so be sure do it soon.<br><br>
|
||||
See you on the activist trail!<br><br>
|
||||
- Animal Rights Map
|
||||
</div>
|
||||
{% endblock %}
|
@ -0,0 +1 @@
|
||||
Activate your Ojuso Identity account.
|
24
ojusomap/templates/registration/login.html
Normal file
24
ojusomap/templates/registration/login.html
Normal file
@ -0,0 +1,24 @@
|
||||
{% extends "base_page.html" %}
|
||||
{% load bootstrap3 %}
|
||||
{% load crispy_forms_tags %}
|
||||
{% load envelope_tags %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block page_title %}{% trans "Login"%} | Ojuso{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container" style="max-width:520px;">
|
||||
<div class="page-lead">
|
||||
<h2>Login</h2>
|
||||
<p class="lead">{% trans "Welcome!" %}</p>
|
||||
</div>
|
||||
{% bootstrap_messages %}
|
||||
<form action="{% url 'auth_login' %}" method="post">
|
||||
{% csrf_token %}
|
||||
{% antispam_fields %}
|
||||
{{form|crispy}}
|
||||
<p><a href="{% url 'auth_password_reset' %}">{% trans "Lost password?" %}</a></p>
|
||||
<input class="btn btn-success pull-right" type="submit" name="submit" value="{% trans 'Login' %}"/>
|
||||
</form>
|
||||
</div>
|
||||
{% endblock %}
|
11
ojusomap/templates/registration/logout.html
Normal file
11
ojusomap/templates/registration/logout.html
Normal file
@ -0,0 +1,11 @@
|
||||
{% extends "base_page.html" %}
|
||||
{% load bootstrap3 %}
|
||||
{% load crispy_forms_tags %}
|
||||
{% load envelope_tags %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block page_name %}Registration{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<p class="text-center">{% trans "You've just been logged out." %} <a href="{% url 'auth_login' %}">{% trans "Click here to login again." %}</p>
|
||||
{% endblock %}
|
14
ojusomap/templates/registration/password_reset_email.html
Normal file
14
ojusomap/templates/registration/password_reset_email.html
Normal file
@ -0,0 +1,14 @@
|
||||
{% load i18n %}{% autoescape off %}
|
||||
{% blocktrans %}You're receiving this email because you requested a password reset for your user account at {{ site_name }}.{% endblocktrans %}
|
||||
|
||||
{% trans "Please go to the following page and choose a new password:" %}
|
||||
{% block reset_link %}
|
||||
{{ protocol }}://{{ domain }}{% url 'auth_password_reset_confirm' uidb64=uid token=token %}
|
||||
{% endblock %}
|
||||
{% trans "Your username, in case you've forgotten:" %} {{ user.get_username }}
|
||||
|
||||
{% trans "Thanks for using our site!" %}
|
||||
|
||||
{% blocktrans %}The {{ site_name }} team{% endblocktrans %}
|
||||
|
||||
{% endautoescape %}
|
12
ojusomap/templates/registration/registration_closed.html
Normal file
12
ojusomap/templates/registration/registration_closed.html
Normal file
@ -0,0 +1,12 @@
|
||||
{% extends "base_page.html" %}
|
||||
{% load bootstrap3 %}
|
||||
{% block page_name %}Registration{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container">
|
||||
<div class="page-lead">
|
||||
<h2>Registration</h2>
|
||||
<p class="lead">Account registration is currently closed. Come back soon!</p>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
22
ojusomap/templates/registration/registration_form.html
Normal file
22
ojusomap/templates/registration/registration_form.html
Normal file
@ -0,0 +1,22 @@
|
||||
{% extends "base_page.html" %}
|
||||
{% load bootstrap3 %}
|
||||
{% load crispy_forms_tags %}
|
||||
{% load envelope_tags %}
|
||||
|
||||
{% block page_name %}Registration{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container" style="max-width:520px;">
|
||||
<div class="page-lead">
|
||||
<h2>Registration</h2>
|
||||
<p class="lead">Create your account and get active!</p>
|
||||
</div>
|
||||
{% bootstrap_messages %}
|
||||
<form action="{% url 'registration_register' %}" method="post">
|
||||
{% csrf_token %}
|
||||
{% antispam_fields %}
|
||||
{{ form|crispy }}
|
||||
<input class="btn btn-success pull-right" type="submit" name"submit" value"Register"/>
|
||||
</form>
|
||||
</div>
|
||||
{% endblock %}
|
Reference in New Issue
Block a user