Submitovatko: bugfixy

This commit is contained in:
Tomas "Jethro" Pokorny 2020-02-28 21:42:06 +01:00
parent 62b0b4a62f
commit fe5cf93ed8

View file

@ -1178,8 +1178,9 @@ class SubmitSolutionView(LoginRequiredMixin, CreateView):
with transaction.atomic():
self.object = form.save()
self.object.resitele.add(Resitel.objects.get(osoba__user = self.request.user))
self.object.cas_doruceni = datetime.now()
self.object.cas_doruceni = timezone.now()
self.object.forma = s.Reseni.FORMA_UPLOAD
self.object.save()
if prilohy.is_valid():
prilohy.instance = self.object
prilohy.save()