You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
from django.shortcuts import render
|
|
|
|
|
|
|
|
from various import utils
|
|
|
|
from personalni.models import Resitel
|
|
|
|
|
|
|
|
|
|
|
|
def StavDatabazeView(request):
|
|
|
|
# nastaveni = Nastaveni.objects.get()
|
|
|
|
problemy = utils.seznam_problemu()
|
|
|
|
muzi = Resitel.objects.filter(osoba__pohlavi_muz=True)
|
|
|
|
zeny = Resitel.objects.filter(osoba__pohlavi_muz=False)
|
|
|
|
return render(
|
|
|
|
request,
|
|
|
|
'seminar/stav_databaze.html',
|
|
|
|
{
|
|
|
|
# 'nastaveni': nastaveni,
|
|
|
|
'problemy': problemy,
|
|
|
|
|
|
|
|
'resitele': Resitel.objects.all(),
|
|
|
|
'muzi': muzi,
|
|
|
|
'zeny': zeny,
|
|
|
|
'jmena_muzu': utils.histogram([r.osoba.jmeno for r in muzi]),
|
|
|
|
'jmena_zen': utils.histogram([r.osoba.jmeno for r in zeny]),
|
|
|
|
}
|
|
|
|
)
|