diff --git a/core/management/commands/populate.py b/core/management/commands/populate.py
index f1b6c0a8..dc5d3efb 100644
--- a/core/management/commands/populate.py
+++ b/core/management/commands/populate.py
@@ -117,7 +117,7 @@ Cette page vise à documenter la syntaxe *Markdown* utilisée sur le site.
p.set_lock(skia)
p.save()
with open(os.path.join(root_path)+'/README.md', 'r') as rm:
- PageRev(page=p, title="REAMDE", author=skia, content=rm.read()).save()
+ PageRev(page=p, title="README", author=skia, content=rm.read()).save()
# Subscription
## Skia
diff --git a/core/static/core/base.css b/core/static/core/base.css
new file mode 100644
index 00000000..35eced0d
--- /dev/null
+++ b/core/static/core/base.css
@@ -0,0 +1,45 @@
+/*--------------------------------RESET--------------------------------*/
+/*--------------------------------RESET--------------------------------*/
+html, body, div, span, applet, object, iframe,
+h1, h2, h3, h4, h5, h6, p, blockquote, pre,
+a, abbr, acronym, address, big, cite, code,
+del, dfn, em, img, ins, kbd, q, s, samp,
+small, strike, strong, sub, sup, tt, var,
+b, u, i, center,
+dl, dt, dd, ol, ul, li,
+fieldset, form, label, legend,
+table, caption, tbody, tfoot, thead, tr, th, td,
+article, aside, canvas, details, embed,
+figure, figcaption, footer, header, hgroup,
+menu, nav, output, ruby, section, summary,
+time, mark, audio, video {
+ margin: 0;
+ padding: 0;
+ border: 0;
+ font-size: 100%;
+ font: inherit;
+ vertical-align: baseline;
+}
+/* HTML5 display-role reset for older browsers */
+article, aside, details, figcaption, figure,
+footer, header, hgroup, menu, nav, section {
+ display: block;
+}
+body {
+ line-height: 1;
+}
+ol, ul {
+ list-style: none;
+}
+blockquote, q {
+ quotes: none;
+}
+blockquote:before, blockquote:after,
+q:before, q:after {
+ content: '';
+ content: none;
+}
+table {
+ border-collapse: collapse;
+ border-spacing: 0;
+}
diff --git a/core/static/core/form.css b/core/static/core/form.css
new file mode 100644
index 00000000..007f1cbb
--- /dev/null
+++ b/core/static/core/form.css
@@ -0,0 +1,188 @@
+/* ----------------------------------------------------------------------------------------------------
+Super Form Reset
+----------------------------------------------------------------------------------------------------*/
+
+input,
+label,
+select,
+button,
+textarea
+{
+ margin: 0;
+ border: 0;
+ padding: 0;
+ display: inline-block;
+ vertical-align: middle;
+ white-space: normal;
+ background: none;
+ line-height: 1;
+
+ /* Browsers have different default form fonts */
+ font-size: 13px;
+ font-family: Arial;
+}
+
+/* Remove the stupid outer glow in Webkit */
+input:focus
+{
+ outline: 0;
+}
+
+/* Box Sizing Reset
+-----------------------------------------------*/
+
+/* All of our custom controls should be what we expect them to be */
+input,
+textarea
+{
+ -webkit-box-sizing: content-box;
+ -moz-box-sizing: content-box;
+ box-sizing: content-box;
+}
+
+/* These elements are usually rendered a certain way by the browser */
+button,
+input[type=reset],
+input[type=button],
+input[type=submit],
+input[type=checkbox],
+input[type=radio],
+select
+{
+ -webkit-box-sizing: border-box;
+ -moz-box-sizing: border-box;
+ box-sizing: border-box;
+}
+
+/* Text Inputs
+-----------------------------------------------*/
+
+input[type=date],
+input[type=datetime],
+input[type=datetime-local],
+input[type=email],
+input[type=month],
+input[type=number],
+input[type=password],
+input[type=range],
+input[type=search],
+input[type=tel],
+input[type=text],
+input[type=time],
+input[type=url],
+input[type=week]
+{
+ background-color: white;
+ border: 1px solid black;
+ padding: 2px;
+ border-radius: 2px;
+}
+
+/* Button Controls
+-----------------------------------------------*/
+
+input[type=checkbox],
+input[type=radio]
+{
+ width: 13px;
+ height: 13px;
+}
+
+/* File Uploads
+-----------------------------------------------*/
+
+input[type=file]
+{
+
+}
+
+/* Search Input
+-----------------------------------------------*/
+
+/* Make webkit render the search input like a normal text field */
+input[type=search]
+{
+ -webkit-appearance: textfield;
+ -webkit-box-sizing: content-box;
+}
+
+/* Turn off the recent search for webkit. It adds about 15px padding on the left */
+::-webkit-search-decoration
+{
+ display: none;
+}
+
+/* Buttons
+-----------------------------------------------*/
+
+button,
+input[type="reset"],
+input[type="button"],
+input[type="submit"]
+{
+ /* Fix IE7 display bug */
+ overflow: visible;
+ width: auto;
+ cursor: pointer;
+ padding: 3px;
+ border: 1px solid black;
+ border-radius: 2px;
+ background-color: white;
+}
+
+button:hover,
+input[type="reset"]:hover,
+input[type="button"]:hover,
+input[type="submit"]:hover
+{
+ box-shadow: 0 0 2px #000;
+}
+
+button:active,
+input[type="reset"]:active,
+input[type="button"]:active,
+input[type="submit"]:active
+{
+ box-shadow: inset 0 0 2px #000;
+}
+
+/* IE8 and FF freak out if this rule is within another selector */
+::-webkit-file-upload-button
+{
+ padding: 0;
+ border: 0;
+ background: none;
+}
+
+/* Textarea
+-----------------------------------------------*/
+
+textarea
+{
+ /* Move the label to the top */
+ vertical-align: top;
+
+ /* Turn off scroll bars in IE unless needed */
+ overflow: auto;
+}
+
+/* Selects
+-----------------------------------------------*/
+
+select
+{
+
+}
+
+select[multiple]
+{
+ /* Move the label to the top */
+ vertical-align: top;
+}
+
+/* Tables
+-----------------------------------------------*/
+tbody>tr{
+ display: block;
+ margin: 3px;
+}
diff --git a/core/static/core/img/logo.png b/core/static/core/img/logo.png
new file mode 100644
index 00000000..6d23a853
Binary files /dev/null and b/core/static/core/img/logo.png differ
diff --git a/core/static/core/style.css b/core/static/core/style.css
index 5da7a456..a3a7b5c4 100644
--- a/core/static/core/style.css
+++ b/core/static/core/style.css
@@ -1,9 +1,161 @@
-body {
- background: #EEE;
+/*--------------------------------GENERAL------------------------------*/
+body{
+ background-color:#EEE;
+ position: relative;
+ width: 100%;
+ font-family: sans-serif;
+}
+/*--------------------------------HEADER-------------------------------*/
+#logo {
+ margin-left: 5%;
+}
+header {
+ display: block;
+ position: absolute;
+ top : 0px;
+ right : 8%;
+ left: 40%;
+ background-color:#DDD;
+ height: 3em;
+}
+header a {
+ display: inline-block;
+ color: inherit;
+ text-decoration: none;
+ padding: 1em;
+}
+header a:hover {
+ color: #2D3;
}
-div {
- box-shadow: 2px 2px 10px #888888;
+/*---------------------------------NAV---------------------------------*/
+nav {
+ display: block;
+ width: 90%;
+ margin: 0px auto;
+ background: grey;
+ color: white;
+}
+
+nav a {
+ color: white;
+ font-style: normal;
+ font-weight: bolder;
+ text-decoration: none;
+ display: inline-block;
+ padding: 20px;
+}
+nav a:hover {
+ background: purple;
+}
+
+/*--------------------------------CONTENT------------------------------*/
+#content {
+ width: 88%;
+ margin: 0px auto;
+ padding: 1em 1%;
+ background: white;
+}
+
+h1, h2, h3, h4, h5, h6 {
+ font-weight: bold;
+ margin-top: 0.5em;
+}
+
+h1 {
+ font-size: 160%;
+ margin-left: 50px;
+}
+
+h2 {
+ font-size: 150%;
+ margin-left: 40px;
+}
+
+h3 {
+ font-size: 140%;
+ margin-left: 30px;
+}
+
+h4 {
+ font-size: 130%;
+ margin-left: 20px;
+}
+
+h5 {
+ font-size: 120%;
+ margin-left: 10px;
+}
+
+h6 {
+ font-size: 110%;
+ margin-left: 0px;
+}
+
+p, pre {
+ margin-top: 1em;
+ margin-left: 0px;
+}
+
+ul, ol {
+ margin-top: 1em;
+ list-style-type: disc;
+ margin-left: 25px;
+}
+
+.edit-bar {
+ display: block;
+ margin: 4px;
+}
+.edit-bar a {
+ display: inline-block;
+ margin: 4px;
+}
+
+/*-----------------------------USER PROFILE----------------------------*/
+.user_profile {
+}
+/*---------------------------------PAGE--------------------------------*/
+.page_content {
+ display: block;
margin: 10px;
padding: 10px;
+ background: white;
+}
+
+.page_content code {
+ font-family: monospace;
+ color: white;
+ background: black;
+ display: inline-block;
+ padding: 4px;
+ line-height: 120%;
+}
+
+/*--------------------------------FOOTER-------------------------------*/
+footer{
+ text-align: center;
+}
+
+/*--------------------------------MODALE-------------------------------*/
+.form-wrapper {
+ display: inline-block;
+ position: absolute;
+ top: 0;
+ left: 0;
+ width: 100%;
+ height: 100%;
+ background-color: #DDD;
+ opacity: 0.8;
+ padding: 15px;
+ border-radius: 4px;
+}
+.form-wrapper>form {
+ display: inline-block;
+ position: absolute;
+ padding: 15px;
+ border-radius: 4px;
+ left: 30%;
+ top: 40%;
+ background-color: white;
}
diff --git a/core/templates/core/base.jinja b/core/templates/core/base.jinja
index 22ee71fc..33edbbdc 100644
--- a/core/templates/core/base.jinja
+++ b/core/templates/core/base.jinja
@@ -3,6 +3,8 @@
{% block head %}
{% block title %}Bienvenue sur le Sith de l'AE!{% endblock %}
+
+
@@ -10,28 +12,24 @@
+
+ {% block header %}
- {% block header %}
- {% if user.is_authenticated() %}Hello, {{ user.username }}!{% endif %}
-
- {% if not user.is_authenticated() %}
- Register
- Login
- {% else %}
- Logout
- {% endif %}
-
- {% if user.is_authenticated() %}
-
+ {% if not user.is_authenticated() %}
+ Register |
+ Login
+ {% else %}
+ {{ user.get_display_name() }} |
+ Tools |
+ Logout
{% endif %}
- {% endblock %}
+ {% endblock %}
+
+ Users
+ Pages
+ Clubs
+
{% if error %}
diff --git a/core/templates/core/page_detail.jinja b/core/templates/core/page_detail.jinja
index 889698bf..5c3bb3d2 100644
--- a/core/templates/core/page_detail.jinja
+++ b/core/templates/core/page_detail.jinja
@@ -11,13 +11,14 @@
{% endif %}
You're seeing the page {{ page.get_display_name() }} -
History
+
{% if rev %}
This may not be the last update, you are seeing revision {{ rev.id }}!
{{ rev.title }}
-
{{ rev.content|markdown }}
+
{{ rev.content|markdown }}
{% else %}
{{ page.revisions.last().title }}
-
{{ page.revisions.last().content|markdown }}
+
{{ page.revisions.last().content|markdown }}
{% endif %}
{% endblock %}
diff --git a/core/templates/core/user_detail.jinja b/core/templates/core/user_detail.jinja
index 86272a5e..4e5febd0 100644
--- a/core/templates/core/user_detail.jinja
+++ b/core/templates/core/user_detail.jinja
@@ -5,24 +5,25 @@
{% endblock %}
{% block content %}
-
User Profile
-
Back to list
-
-
+
{% if can_edit(profile, request.user) or user.id == profile.id %}
-
Edit
+
Edit
{% endif %}
{% if can_edit_prop(profile, request.user) %}
-
Props
+
Props
{% endif %}
-
+
-
-You're seeing the profile of {{ profile.get_full_name() }}
-{{ profile.nick_name }}
-{{ profile.date_of_birth|date("d/m/Y") }}
-
+User Profile
+
+
+
{{ profile.get_full_name() }}
+
{{ profile.nick_name }}
+
Born: {{ profile.date_of_birth|date("d/m/Y") }}
+
+
+{% if user.membership.filter(end_date=None).exists() %}
{% if get_subscriber(profile).is_subscribed() %}
User is subscriber until {{ get_subscriber(profile).subscriptions.last().subscription_end }}
@@ -30,6 +31,7 @@ User is subscriber until {{ get_subscriber(profile).subscriptions.last().subscri
User is not subscribed. New subscription
{% endif %}
+{% endif %}
{% endblock %}
diff --git a/core/templates/core/user_edit.jinja b/core/templates/core/user_edit.jinja
index f7ac879d..87489a1b 100644
--- a/core/templates/core/user_edit.jinja
+++ b/core/templates/core/user_edit.jinja
@@ -7,7 +7,9 @@
{{ form.as_p() }}
- Change my password
+ {% if form.instance == user %}
+ Change my password
+ {% endif %}
{% endblock %}
diff --git a/core/templates/core/user_tools.jinja b/core/templates/core/user_tools.jinja
index 443350fd..ec9e6312 100644
--- a/core/templates/core/user_tools.jinja
+++ b/core/templates/core/user_tools.jinja
@@ -6,7 +6,6 @@
{% block content %}
User Tools
-Back to profile
Sith management
diff --git a/counter/templates/counter/counter_main.jinja b/counter/templates/counter/counter_main.jinja
index 156d7cea..7c01f0d9 100644
--- a/counter/templates/counter/counter_main.jinja
+++ b/counter/templates/counter/counter_main.jinja
@@ -32,7 +32,7 @@
{% else %}
Please, login
@@ -48,7 +48,7 @@
{% endblock %}