Přidán filtr podle maturity u aktivniResitele()
Dokumentace to dokonce i slibuje, jen to nebylo implementováno (ono ve skutečnosti podle toho filtruje už resi_v_rocniku, ale resi_v_rocniku(loni) filtruje podle loni, projistotu jsem to přidal na obojí)
This commit is contained in:
		
							parent
							
								
									2efcb4d7d6
								
							
						
					
					
						commit
						b201d881d5
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		|  | @ -212,10 +212,10 @@ def aktivniResitele(cislo, pouze_letosni=False): | |||
| 		zacatek_rocniku = False | ||||
| 
 | ||||
| 	if not zacatek_rocniku: | ||||
| 		return resi_v_rocniku(letos, cislo) | ||||
| 		return resi_v_rocniku(letos, cislo).filter(rok_maturity__gte=letos.druhy_rok()) | ||||
| 	else: | ||||
| 		# spojíme querysety s řešiteli loni a letos do daného čísla | ||||
| 		return (resi_v_rocniku(loni) | resi_v_rocniku(letos, cislo)).distinct() | ||||
| 		return (resi_v_rocniku(loni) | resi_v_rocniku(letos, cislo)).distinct().filter(rok_maturity__gte=letos.druhy_rok()) | ||||
| 
 | ||||
| def viewMethodSwitch(get, post): | ||||
| 	""" | ||||
|  |  | |||
		Loading…
	
		Reference in a new issue