forked from ScoDoc/ScoDoc
Actualiser app/scodoc/sco_edt_cal.py
Simplification du code pour rechercher formsemestre_id
This commit is contained in:
parent
eaa82f61a4
commit
cb13ea2e31
@ -42,7 +42,6 @@ from flask import g, url_for
|
|||||||
from app import log
|
from app import log
|
||||||
from app.auth.models import User
|
from app.auth.models import User
|
||||||
from app.models import FormSemestre, GroupDescr, ModuleImpl, ScoDocSiteConfig
|
from app.models import FormSemestre, GroupDescr, ModuleImpl, ScoDocSiteConfig
|
||||||
from app.scodoc.html_sidebar import retreive_formsemestre_from_request
|
|
||||||
from app.scodoc.sco_exceptions import ScoValueError
|
from app.scodoc.sco_exceptions import ScoValueError
|
||||||
import app.scodoc.sco_utils as scu
|
import app.scodoc.sco_utils as scu
|
||||||
|
|
||||||
@ -232,10 +231,9 @@ def translate_calendar(
|
|||||||
}
|
}
|
||||||
if modimpl:
|
if modimpl:
|
||||||
params["moduleimpl_id"] = modimpl.id
|
params["moduleimpl_id"] = modimpl.id
|
||||||
else:
|
elif group:
|
||||||
params["formsemestre_id"] = retreive_formsemestre_from_request()
|
params["formsemestre_id"] = group.partition.formsemestre_id
|
||||||
|
|
||||||
# Génération de l'URL si group et l'un des deux (modimpl ou formsem) sont définis
|
|
||||||
url_abs = (
|
url_abs = (
|
||||||
url_for("assiduites.signal_assiduites_group", **params)
|
url_for("assiduites.signal_assiduites_group", **params)
|
||||||
if group
|
if group
|
||||||
|
Loading…
Reference in New Issue
Block a user