Praktikum 7 Authentifizieren
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
{% extends 'base.html' %}
|
||||
|
||||
{% block title %}
|
||||
Index
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class=container>
|
||||
<h1 class="display-4">New Message</h1>
|
||||
|
||||
<form method="POST">
|
||||
<div class="form-group">
|
||||
{% csrf_token %}{{ form.as_p }}
|
||||
</div>
|
||||
<button type="submit" class="save btn btn-default">Speichern</button>
|
||||
</form>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -5,14 +5,26 @@ Index
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="jumbotron">
|
||||
<h1 class="display-4">Index of News App</h1>
|
||||
<div class=container>
|
||||
<h1 class="display-4">Your Posts</h1>
|
||||
|
||||
<div class=container>
|
||||
{% for notice in notices %}
|
||||
<h3>{{ notice.notice_title }}</h3>
|
||||
<p>{{ notice.notice_text }}</p>
|
||||
<div class="jumbotron">
|
||||
<h3>{{ notice.notice_title }}</h3>
|
||||
<p>{{ notice.notice_text }}</p>
|
||||
<p><a href="{% url 'delete' deleteId=notice.id %}" class="btn btn-danger" role="button">Delete</a></p>
|
||||
{% if message %}
|
||||
<script>
|
||||
alert('{{ message }}');
|
||||
</script>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
<div class=container>
|
||||
<p><a href="{% url 'new' %}" class="btn btn-info" role="button">Neue Nachricht</a></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--p class="lead">Some placeholder Text</p-->
|
||||
|
||||
Reference in New Issue
Block a user