RANDOMSEC-24 #3

Merged
s434834 merged 2 commits from RANDOMSEC-24 into master 2022-01-27 18:40:06 +01:00
11 changed files with 27 additions and 17 deletions

View File

@ -1,6 +1,6 @@
# MultiUserOpenRefine
![MultiUserOpenRefine](logo.svg)
![MultiUserOpenRefine](Serwer_django/static/images/logo.svg)
MultiUserOpenRefine is an extension to open-source tool that, in addition to
all the features described below, allows creating user accounts, each providing

View File

@ -37,6 +37,7 @@ INSTALLED_APPS = [
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'crispy_forms'
]
MIDDLEWARE = [
@ -130,3 +131,4 @@ LOGOUT_REDIRECT_URL = 'home'
# https://docs.djangoproject.com/en/4.0/ref/settings/#default-auto-field
DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
CRISPY_TEMPLATE_PACK = 'bootstrap4'

Binary file not shown.

View File

@ -1,3 +0,0 @@
body {
background-color: #818fb7;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 147 KiB

View File

Before

Width:  |  Height:  |  Size: 153 KiB

After

Width:  |  Height:  |  Size: 153 KiB

View File

@ -2,17 +2,28 @@
<!DOCTYPE html>
<html>
<head>
{% load static %}
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap-theme.min.css">
<link rel="stylesheet" href="{% static 'base.css'%}">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css"
integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<meta charset="utf-8">
<title>{% block title %}Auth{% endblock %}</title>
<title>{% block title %}MultiUserOpenRefine{% endblock %}</title>
</head>
<body>
<main>
{% block content %}
{% endblock %}
<div class="container">
<div style="position: page; vertical-align: center">
<div class="row justify-content-center">
<div class="col-8">
<img src="../static/images/logo.png" alt="logo"
style="padding-top: 10px; height: auto; width: 50%; display: block; margin-left: auto; margin-right: auto;">
<h1 class="mt-2" style="text-align: center; padding-bottom: 10px">MultiUserOpenRefine</h1>
<div style="border-radius: 25px; border: 4px solid #e0e0e0; padding: 20px; box-shadow: rgba(0, 0, 0, 0.24) 0 3px 8px;">
{% block content %}
{% endblock %}
</div>
</div>
</div>
</div>
</div>
</main>
</body>
</html>

View File

@ -5,11 +5,11 @@
{% block content %}
{% if user.is_authenticated %}
Hi {{ user.username }}!
<p><a href="{% url 'logout' %}">Log Out</a></p>
<p>Hi {{ user.username }}!</p>
<p><a href="{% url 'logout' %}" class="btn btn-light">Log Out</a></p>
{% else %}
<p>You are not logged in</p>
<p><a href="{% url 'login' %}">Log In</a></p>
<p><a href="{% url 'signup' %}">Sign Up</a></p>
<p><a href="{% url 'login' %}" class="btn btn-light">Log In</a></p>
<p><a href="{% url 'signup' %}" class="btn btn-light">Create an account</a></p>
{% endif %}
{% endblock %}

View File

@ -8,6 +8,6 @@
<form method="post">
{% csrf_token %}
{{ form.as_p }}
<button type="submit">Log In</button>
<button class="btn btn-light" type="submit">Log In</button>
</form>
{% endblock %}

View File

@ -8,6 +8,6 @@
<form method="post">
{% csrf_token %}
{{ form.as_p }}
<button type="submit">Sign Up</button>
<button class="btn btn-light" type="submit">Sign Up</button>
</form>
{% endblock %}