VIew view
This commit is contained in:
parent
c4ed1e0792
commit
06f53e8304
1 changed files with 4 additions and 1 deletions
|
@ -59,6 +59,9 @@ def index(request):
|
||||||
return HttpResponse(soup.prettify())
|
return HttpResponse(soup.prettify())
|
||||||
|
|
||||||
def login_view(request):
|
def login_view(request):
|
||||||
|
if request.method == "GET":
|
||||||
|
token = request.GET["token"]
|
||||||
|
else:
|
||||||
token = request.POST["token"]
|
token = request.POST["token"]
|
||||||
user = authenticate(request, username="guest", password=token.lower())
|
user = authenticate(request, username="guest", password=token.lower())
|
||||||
if user is not None:
|
if user is not None:
|
||||||
|
|
Loading…
Reference in a new issue