Skip to content
Snippets Groups Projects
Commit 7233f19b authored by frekk's avatar frekk
Browse files

make styling less awful and rejiggle templates

parent 3aaac7c8
Branches
Tags
No related merge requests found
...@@ -5,7 +5,7 @@ html { ...@@ -5,7 +5,7 @@ html {
body { body {
min-height: 100%; min-height: 100%;
position: relative; position: relative;
background-color: yellow; background-color: #f8f8f8;
font-family: Arial, Helvetica, sans-serif; font-family: Arial, Helvetica, sans-serif;
margin: 0; margin: 0;
} }
...@@ -28,16 +28,27 @@ body { ...@@ -28,16 +28,27 @@ body {
.form-container { .form-container {
background-color: #ffe; background-color: #ffe;
border-style: 2px solid #8fc; border: 2px solid #8fc;
border-radius: 5px; border-radius: 5px;
padding: 20px; padding: 20px;
margin: 10px; margin: 10px;
} }
.form-container .tips { .form-header {
margin: 10px 10px 20px 10px; text-align: center;
color: #555; padding: 10px 10px 20px 10px;
}
.form-header .tips {
color: #333;
font-weight: 400;
font-size: 17px;
border-radius: 10px;
background-color: #feb;
padding: 10px 10px 7px 10px;
display: inline-block;
text-align: center; text-align: center;
line-height: 23px;
} }
fieldset { fieldset {
......
...@@ -12,6 +12,33 @@ ...@@ -12,6 +12,33 @@
background-size: cover; background-size: cover;
} }
/* MESSAGES & ERRORS */
ul.messagelist {
padding: 0;
margin: 0;
}
ul.messagelist li {
display: block;
font-weight: 400;
font-size: 13px;
padding: 10px 10px 10px 65px;
margin: 0 0 10px 0;
background: #dfd url(../img/icon-yes.svg) 40px 12px no-repeat;
background-size: 16px auto;
color: #333;
}
ul.messagelist li.warning {
background: #ffc url(../img/icon-alert.svg) 40px 14px no-repeat;
background-size: 14px auto;
}
ul.messagelist li.error {
background: #ffefef url(../img/icon-no.svg) 40px 12px no-repeat;
background-size: 16px auto;
}
.errornote { .errornote {
font-size: 14px; font-size: 14px;
font-weight: 700; font-weight: 700;
......
...@@ -17,8 +17,6 @@ ...@@ -17,8 +17,6 @@
<!-- Header --> <!-- Header -->
<div id="header"> <div id="header">
{% block header %}{% endblock %}
{% block navbar %} {% block navbar %}
<nav> <nav>
{% block branding %} {% block branding %}
...@@ -41,6 +39,14 @@ ...@@ -41,6 +39,14 @@
{% endwith %} {% endwith %}
</nav> </nav>
{% endblock %} {% endblock %}
{% block header %}{% endblock %}
{% block messages %}{% if messages %}
<ul class="messagelist">{% for message in messages %}
<li{% if message.tags %} class="{{ message.tags }}"{% endif %}>{{ message|capfirst }}</li>
{% endfor %}</ul>
{% endif %}{% endblock messages %}
</div> </div>
<!-- END Header --> <!-- END Header -->
......
...@@ -6,10 +6,10 @@ ...@@ -6,10 +6,10 @@
{% block tips %} {% block tips %}
{% if not object %} {% if not object %}
<b>Your account exists already but no membership information has yet been recorded in this system.</b> <b>You have no member record associated with this account.</b><br>
<br>Please update/correct the details below as necessary. Please <a href="{% url 'memberdb:renew' %}">renew your membership</a> to get started.
{% else %} {% else %}
Please confirm that the details below have not changed since your last registration or membership renewal. You can see and modify some of your membership and account details below.
{% endif %} {% endif %}
{% endblock %} {% endblock %}
...@@ -20,6 +20,10 @@ Please confirm that the details below have not changed since your last registrat ...@@ -20,6 +20,10 @@ Please confirm that the details below have not changed since your last registrat
</div> </div>
{% endblock %} {% endblock %}
{% block action_url %}{% url 'memberdb:renew' %}{% endblock %} {% block form %}
{% if object %} {{ block.super }} {% endif %}
{% endblock %}
{% block action_url %}{% url 'memberdb:home' %}{% endblock %}
{% block action_text %}Renew{% endblock %} {% block action_text %}Update details{% endblock %}
\ No newline at end of file \ No newline at end of file
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<div class="form-container"> <div class="form-container">
<div class="form-header">
{% if form.errors and not form.non_field_errors %} {% if form.errors and not form.non_field_errors %}
<p class="errornote"> <p class="errornote">
{% if form.errors.items|length == 1 %}Please correct the error below.{% else %}Please correct the errors below.{% endif %} {% if form.errors.items|length == 1 %}Please correct the error below.{% else %}Please correct the errors below.{% endif %}
...@@ -39,6 +40,7 @@ ...@@ -39,6 +40,7 @@
If you do not have a UCC account yet, please apply for a membership by going to the <a href="{% url 'memberdb:register' %}">registration page</a>. If you do not have a UCC account yet, please apply for a membership by going to the <a href="{% url 'memberdb:register' %}">registration page</a>.
{% endif %} {% endif %}
</p> </p>
</div>
<form action="{% url 'memberdb:login' %}" method="post" id="login-form"> <form action="{% url 'memberdb:login' %}" method="post" id="login-form">
{% csrf_token %} {% csrf_token %}
......
...@@ -6,12 +6,15 @@ ...@@ -6,12 +6,15 @@
{% block content %} {% block content %}
<div class="form-container"> <div class="form-container">
<p class="tips"> <div class="form-header">
<span class="tips">
{% block tips %} {% block tips %}
Enter your details, and press "Register" when you are done.<br> Enter your details, and press "Register" when you are done.<br>
Once your membership has been approved, you will receive an email with further instructions to activate your account. Once your membership has been approved, you will receive an email with further instructions to activate your account.
{% endblock %} {% endblock %}
</p> </span>
</div>
{% block form %}
<form action="{% block action_url %}{% url 'memberdb:register' %}{% endblock %}" method="post"> <form action="{% block action_url %}{% url 'memberdb:register' %}{% endblock %}" method="post">
{% csrf_token %} {% csrf_token %}
...@@ -41,5 +44,6 @@ ...@@ -41,5 +44,6 @@
<input type="submit" class="default" value="{% block action_text %}Register{% endblock %}"> <input type="submit" class="default" value="{% block action_text %}Register{% endblock %}">
</div> </div>
</form> </form>
{% endblock %}
</div> </div>
{% endblock %} {% endblock %}
\ No newline at end of file
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
{% block tips %} {% block tips %}
{% if is_new %} {% if is_new %}
<b>Your account exists already but no membership information has yet been recorded in this system.</b> <b>Your account exists already but no membership information has yet been recorded in this system.</b>
<br>Please update/correct the details below as necessary. <br>Please update/correct the details below as necessary. Some have probably been filled for you.
{% else %} {% else %}
Please confirm that the details below have not changed since your last registration or membership renewal. Please confirm that the details below have not changed since your last registration or membership renewal.
{% endif %} {% endif %}
......
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