add login functionality

This commit is contained in:
Andreas Zweili 2019-08-25 22:35:03 +02:00
parent 5cdbf760e0
commit 9d859f4ffc
2 changed files with 13 additions and 1 deletions

View File

@ -0,0 +1,11 @@
{% extends 'inventory/base.html' %}
{% block section_title %}Login{% endblock %}
{% block content %}
<form id="login" name="login" method="post">
{% csrf_token %}
{{ form.as_p }}
<button name="button_login" type="submit">Login</button>
</form>
{% endblock %}

View File

@ -1,8 +1,9 @@
from django.urls import path
from django.urls import path, include
from . import views
urlpatterns = [
path('accounts/', include('django.contrib.auth.urls')),
path('', views.customers_table_view, name='customers'),
path('customer/<int:pk>/', views.CustomerDetailView.as_view(),
name='customer'),