formsemestre_bulletinetud avec arg INE: filtre sur dept
This commit is contained in:
parent
96b59294a1
commit
264ef7e1ff
@ -290,16 +290,17 @@ def formsemestre_bulletinetud(
|
||||
if etudid:
|
||||
etud = models.Identite.query.get_or_404(etudid)
|
||||
elif code_nip:
|
||||
dept = formsemestre.dept_id
|
||||
etud = (
|
||||
models.Identite.query.filter_by(code_nip=str(code_nip))
|
||||
.filter_by(dept_id=dept)
|
||||
.filter_by(dept_id=formsemestre.dept_id)
|
||||
.first_or_404()
|
||||
)
|
||||
elif code_ine:
|
||||
etud = models.Identite.query.filter_by(
|
||||
code_ine=str(code_ine)
|
||||
).first_or_404()
|
||||
etud = (
|
||||
models.Identite.query.filter_by(code_ine=str(code_ine))
|
||||
.filter_by(dept_id=formsemestre.dept_id)
|
||||
.first_or_404()
|
||||
)
|
||||
else:
|
||||
raise ScoValueError(
|
||||
"Paramètre manquant: spécifier code_nip ou etudid ou code_ine"
|
||||
|
Loading…
Reference in New Issue
Block a user