Fix: Ve výsl. zobraz body <=> ř. se pokusil o ř.
This commit is contained in:
		
							parent
							
								
									871008c6bf
								
							
						
					
					
						commit
						da988f27e6
					
				
					 1 changed files with 6 additions and 2 deletions
				
			
		|  | @ -209,7 +209,10 @@ class CisloView(generic.DetailView): | |||
|             v.poradi = poradi | ||||
|             v.body_celkem_rocnik = v.body | ||||
|             v.body_celkem_odjakziva = VysledkyKCisluOdjakziva.objects.get(resitel=v.resitel, cislo=context['cislo']).body | ||||
|             v.body_ulohy = [0] * len(problemy) | ||||
| 
 | ||||
|             # je tady '', aby se nezobrazovala 0, pokud se řešitel o řešení úlohy ani nepokusil | ||||
|             v.body_ulohy = [''] * len(problemy) | ||||
| 
 | ||||
|             v.titul = v.resitel.get_titul(v.body_celkem_odjakziva) | ||||
| 
 | ||||
|             body_cislo_q = VysledkyZaCislo.objects.filter(resitel=v.resitel, cislo=context['cislo']) | ||||
|  | @ -233,7 +236,8 @@ class CisloView(generic.DetailView): | |||
| class ArchivTemataView(generic.ListView): | ||||
|     model = Problem | ||||
|     template_name = 'seminar/archiv/temata.html' | ||||
|     queryset = Problem.objects.filter(typ=Problem.TYP_TEMA).order_by('cislo_zadani__rocnik__rocnik', 'kod') | ||||
|     query = Problem.objects.filter(typ=Problem.TYP_TEMA).select_related('cislo_zadani__rocnik__rocnik').order_by('-cislo_zadani__rocnik__rocnik', 'kod') | ||||
|     queryset = [{"rocnik": r, "temata": list(x)} for r, x in groupby(query, lambda x: x.cislo_zadani.rocnik.rocnik)] | ||||
| 
 | ||||
| ### Generovani vysledkovky | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
		Reference in a new issue
	
	 Matěj Kocián
						Matěj Kocián