select_related musi odkazovat na klic, nikoli atribut.
This commit is contained in:
		
							parent
							
								
									b1cc6df91e
								
							
						
					
					
						commit
						cfa9bd9056
					
				
					 1 changed files with 3 additions and 3 deletions
				
			
		|  | @ -502,7 +502,7 @@ class CisloView(generic.DetailView): | |||
| class ArchivTemataView(generic.ListView): | ||||
|     model = Problem | ||||
|     template_name = 'seminar/archiv/temata.html' | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_TEMA, stav=Problem.STAV_ZADANY).select_related('cislo_zadani__rocnik__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_TEMA, stav=Problem.STAV_ZADANY).select_related('cislo_zadani__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
| 
 | ||||
| ### Generovani vysledkovky | ||||
| 
 | ||||
|  | @ -704,12 +704,12 @@ def soustredeniUcastniciExportView(request,soustredeni): | |||
| class ClankyResitelView(generic.ListView): | ||||
|     model = Problem | ||||
|     template_name = 'seminar/clanky/resitelske_clanky.html' | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_RES_CLANEK, stav=Problem.STAV_ZADANY).select_related('cislo_zadani__rocnik__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_RES_CLANEK, stav=Problem.STAV_ZADANY).select_related('cislo_zadani__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
| 
 | ||||
| class ClankyOrganizatorView(generic.ListView): | ||||
|     model = Problem | ||||
|     template_name = 'seminar/clanky/organizatorske_clanky.html' | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_ORG_CLANEK, stav=Problem.STAV_ZADANY).select_related('cislo_zadani__rocnik__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_ORG_CLANEK, stav=Problem.STAV_ZADANY).select_related('cislo_zadani__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
| 
 | ||||
| 
 | ||||
| ### Status | ||||
|  |  | |||
		Loading…
	
		Reference in a new issue