This repository has been archived on 2025-09-03. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
Employee-Management-Portal/work/views.py
Alicja Cięciwa e19cde9660 icon and title
2020-11-11 21:20:23 +01:00

17 lines
457 B
Python

from django.http import HttpResponseRedirect
from django.shortcuts import render
from work.forms import HoursInputForm
def get_basic_workdata(request):
title = 'Rejestracja'
if request.method == 'POST':
form = HoursInputForm(request.POST)
if form.is_valid():
return HttpResponseRedirect('/home/')
else:
form = HoursInputForm()
return render(request, 'inputhours.html', {'form': form, 'title': title})