add login and logout button to base.html

This commit is contained in:
Andreas Zweili 2019-08-30 06:21:27 +02:00
parent f86e1f0c6d
commit f4f8fb95fe
1 changed files with 7 additions and 2 deletions

View File

@ -7,8 +7,13 @@
</head>
<body>
<div class="ui container">
<a href="{% url 'customers' %}">Home</a> |
<a href="{% url 'all_computers' %}">All Computers</a> |
<a href="{% url 'customers' %}">Home</a> |
<a href="{% url 'all_computers' %}">All Computers</a> |
{% if user.is_authenticated %}
<a href="{% url 'logout' %}">Logout</a> |
{% else %}
<a href="{% url 'login' %}" >Login</a> |
{% endif %}
<h1>{% block section_title %}Device Inventory{% endblock %}</h1>
{% block content %}{% endblock %}
<footer>