Merge branch 'master' of atrey.karlin.mff.cuni.cz:/akce/MaM/MaMweb/mamweb
This commit is contained in:
commit
1393d73559
1 changed files with 2 additions and 1 deletions
|
@ -384,13 +384,14 @@ def obalkyView(request,resitele):
|
||||||
|
|
||||||
### Tituly
|
### Tituly
|
||||||
|
|
||||||
|
# TODO udelat neco jako get_objects_or_404
|
||||||
def TitulyView(request, rocnik, cislo):
|
def TitulyView(request, rocnik, cislo):
|
||||||
rocnik_obj = Rocnik.objects.filter(rocnik = rocnik).first()
|
rocnik_obj = Rocnik.objects.filter(rocnik = rocnik).first()
|
||||||
resitele = Resitel.objects.filter(rok_maturity__gte = rocnik_obj.prvni_rok)
|
resitele = Resitel.objects.filter(rok_maturity__gte = rocnik_obj.prvni_rok)
|
||||||
cislo_obj = Cislo.objects.filter(rocnik = rocnik_obj, cislo = cislo).first()
|
cislo_obj = Cislo.objects.filter(rocnik = rocnik_obj, cislo = cislo).first()
|
||||||
|
|
||||||
for resitel in resitele:
|
for resitel in resitele:
|
||||||
vys = VysledkyKCisluOdjakziva.objects.filter(resitel = resitele, cislo = cislo_obj).first()
|
vys = VysledkyKCisluOdjakziva.objects.filter(resitel = resitel, cislo = cislo_obj).first()
|
||||||
if vys == None:
|
if vys == None:
|
||||||
body = 0
|
body = 0
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue