
- Added verbose names for Incident and ResidualRisk models for better clarity in admin interface. - Updated impact choices for ResidualRisk and Risk models to ensure consistency and clarity. - Implemented gettext_lazy for translatable strings in models and choices. - Enhanced the Risk, ResidualRisk, Control, AuditLog, and Incident models with Meta options for better admin representation. - Added login required decorators to views for improved security. - Introduced new CSS variables and classes for better visual representation of risk levels. - Created custom template tags for dynamic CSS class assignment based on risk likelihood and impact. - Improved dashboard and statistics views with user authentication checks. - Updated templates for risks, controls, incidents, and admin interface to include edit and delete options for staff users. - Added new login and logout templates for user authentication. - Enhanced list views for risks, controls, and incidents to include action buttons for staff users. - Improved overall UI/UX with Bulma CSS framework for a more modern look and feel.
109 lines
4 KiB
HTML
109 lines
4 KiB
HTML
{% load static %}
|
||
<!doctype html>
|
||
<html lang="de">
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<title>Login</title>
|
||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||
|
||
<!-- Wenn Bulma bereits global geladen wird, diesen Link entfernen -->
|
||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@1.0.2/css/bulma.min.css">
|
||
</head>
|
||
<body class="has-background-light">
|
||
|
||
<section class="hero is-fullheight">
|
||
<div class="hero-body">
|
||
<div class="container">
|
||
<div class="columns is-centered">
|
||
<div class="column is-4-widescreen is-5-desktop is-6-tablet">
|
||
|
||
<div class="card">
|
||
<header class="card-header">
|
||
<p class="card-header-title">Bitte anmelden</p>
|
||
</header>
|
||
|
||
<div class="card-content">
|
||
{% if form.non_field_errors %}
|
||
<div class="notification is-danger is-light">
|
||
{% for error in form.non_field_errors %}
|
||
<p>{{ error }}</p>
|
||
{% endfor %}
|
||
</div>
|
||
{% endif %}
|
||
|
||
<form method="post" action="{% url 'login' %}">
|
||
{% csrf_token %}
|
||
|
||
<!-- Benutzername -->
|
||
<div class="field">
|
||
<label class="label" for="{{ form.username.id_for_label }}">Benutzername</label>
|
||
<div class="control has-icons-left">
|
||
<input
|
||
class="input{% if form.username.errors %} is-danger{% endif %}"
|
||
type="text"
|
||
name="{{ form.username.html_name }}"
|
||
id="{{ form.username.id_for_label }}"
|
||
value="{{ form.username.value|default:'' }}"
|
||
placeholder="z. B. maxmustermann"
|
||
autocomplete="username"
|
||
required>
|
||
<span class="icon is-left">👤</span>
|
||
</div>
|
||
{% if form.username.errors %}
|
||
{% for error in form.username.errors %}
|
||
<p class="help is-danger">{{ error }}</p>
|
||
{% endfor %}
|
||
{% endif %}
|
||
</div>
|
||
|
||
<!-- Passwort -->
|
||
<div class="field">
|
||
<label class="label" for="{{ form.password.id_for_label }}">Passwort</label>
|
||
<div class="control has-icons-left">
|
||
<input
|
||
class="input{% if form.password.errors %} is-danger{% endif %}"
|
||
type="password"
|
||
name="{{ form.password.html_name }}"
|
||
id="{{ form.password.id_for_label }}"
|
||
placeholder="••••••••"
|
||
autocomplete="current-password"
|
||
required>
|
||
<span class="icon is-left">🔒</span>
|
||
</div>
|
||
{% if form.password.errors %}
|
||
{% for error in form.password.errors %}
|
||
<p class="help is-danger">{{ error }}</p>
|
||
{% endfor %}
|
||
{% endif %}
|
||
</div>
|
||
|
||
<input type="hidden" name="next" value="{{ next }}">
|
||
|
||
<div class="field is-grouped is-justify-content-space-between is-align-items-center">
|
||
<div class="control">
|
||
<button type="submit" class="button is-primary">
|
||
Anmelden
|
||
</button>
|
||
</div>
|
||
<div class="control">
|
||
<a class="button is-text" href="{% url 'password_reset' %}">Passwort vergessen?</a>
|
||
</div>
|
||
</div>
|
||
</form>
|
||
</div>
|
||
|
||
<footer class="card-footer">
|
||
<span class="card-footer-item">
|
||
<span class="is-size-7 has-text-grey">© {% now "Y" %} – WIRA Risk Management</span>
|
||
</span>
|
||
</footer>
|
||
</div>
|
||
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</section>
|
||
|
||
</body>
|
||
</html>
|