praktikum Aufgabe7 * Style geändert
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
{% extends "base.html" %}
|
||||
{% block content %}
|
||||
|
||||
<h1>Neue Nachricht</h1>
|
||||
<form method="POST">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p }}
|
||||
<button type="submit" class="save btn btn-default">Speichern</button>
|
||||
</form>
|
||||
|
||||
<h1>Neue Nachricht</h1>
|
||||
<form method="POST">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p }}
|
||||
<button type="submit" class="save btn btn-default">Speichern</button>
|
||||
</form>
|
||||
{% if user.is_authenticated %}
|
||||
<p><a href="{% url 'logout' %}?next=/posts/home"
|
||||
class="btn btn-warning">Abmelden</a></p>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
|
||||
<div class="card w-100">
|
||||
<div class="card-body">
|
||||
<div class="card-body jumbotron" style="background: ghostwhite">
|
||||
{% for notice in allnotice %}
|
||||
<h5 class="card-title">{{ notice.notice_title }}</h5>
|
||||
<p class="card-text">{{ notice.notice_text |linebreaks }}</p>
|
||||
@@ -17,4 +17,10 @@
|
||||
</div>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
|
||||
<style>
|
||||
.test{
|
||||
background-color: darkgray;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,32 @@
|
||||
{% extends 'base.html' %}
|
||||
{% block title %}
|
||||
Login
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
|
||||
{% if next %}
|
||||
{% if user.is_authenticated %}
|
||||
<p>Your account doesn't have access to this page. To proceed,
|
||||
please login with an account that has access.</p>
|
||||
{% else %}
|
||||
<p>Please login to see this page.</p>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
<form method="post" action="{% url 'login' %}">
|
||||
{% csrf_token %}
|
||||
<div>
|
||||
<tb>{{ form.username.label_tag }}</tb>
|
||||
<p>{{ form.username }}</p>
|
||||
</div>
|
||||
<div>
|
||||
<p>{{ form.password.label_tag }}</p>
|
||||
<p>{{ form.password }}</p>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<input type="submit" value="login"/>
|
||||
<input type="hidden" name="next" value="{{ next }}"/>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user