Initial commit

This commit is contained in:
2022-09-15 22:25:55 +03:00
commit 7582330b1b
70 changed files with 1094 additions and 0 deletions

21
account/views.py Normal file
View File

@@ -0,0 +1,21 @@
from django.shortcuts import render
from django.http import HttpResponse
from .forms import SiteUserForm
def index(request):
if request.method == 'POST':
form = SiteUserForm(request.POST)
if form.is_valid():
form.save()
return HttpResponse("User was created successfully.")
else:
return HttpResponse("There was an error.")
else:
form = SiteUserForm()
return render(request, 'account.html', {'form': form})
# def index(request):
# return render(request, 'account.html')