formsemestre et etudiant fini
This commit is contained in:
parent
401a43378d
commit
ba0062135b
@ -53,9 +53,10 @@ from app.models import ApcReferentielCompetences
|
||||
from app.scodoc.sco_abs import annule_absence, annule_justif
|
||||
from app.scodoc.sco_bulletins import formsemestre_bulletinetud_dict
|
||||
from app.scodoc.sco_bulletins_json import make_json_formsemestre_bulletinetud
|
||||
from app.scodoc.sco_evaluation_db import do_evaluation_get_all_notes
|
||||
from app.scodoc.sco_formations import formation_export
|
||||
from app.scodoc.sco_formsemestre_inscriptions import do_formsemestre_inscription_listinscrits
|
||||
from app.scodoc.sco_groups import setGroups, get_etud_groups
|
||||
from app.scodoc.sco_groups import setGroups, get_etud_groups, get_group_members
|
||||
from app.scodoc.sco_moduleimpl import moduleimpl_list
|
||||
from app.scodoc.sco_permissions import Permission
|
||||
|
||||
@ -63,6 +64,7 @@ from app.scodoc.sco_permissions import Permission
|
||||
############################################### Departements ##########################################################
|
||||
from app.scodoc.sco_prepajury import feuille_preparation_jury
|
||||
from app.scodoc.sco_pvjury import formsemestre_pvjury
|
||||
from app.scodoc.sco_recapcomplet import formsemestre_recapcomplet
|
||||
|
||||
|
||||
@bp.route("/departements", methods=["GET"])
|
||||
@ -441,15 +443,29 @@ def bulletins(formsemestre_id: int):
|
||||
"""
|
||||
Les bulletins d'un formsemestre donné
|
||||
"""
|
||||
return error_response(501, message="Not implemented")
|
||||
# fonction to use : formsemestre_recapcomplet
|
||||
|
||||
try:
|
||||
data = formsemestre_recapcomplet(formsemestre_id)
|
||||
except ValueError:
|
||||
return error_response(409, message="La requête ne peut être traitée en l’état actuel")
|
||||
|
||||
return jsonify(data)
|
||||
|
||||
|
||||
@bp.route("/formsemestre/<int:formsemestre_id>/jury", methods=["GET"])
|
||||
def jury(formsemestre_id: int):
|
||||
"""
|
||||
|
||||
Le récapitulatif des décisions jury
|
||||
"""
|
||||
return error_response(501, message="Not implemented")
|
||||
# fonction to use : formsemestre_pvjury
|
||||
|
||||
try:
|
||||
data = formsemestre_pvjury(formsemestre_id)
|
||||
except ValueError:
|
||||
return error_response(409, message="La requête ne peut être traitée en l’état actuel")
|
||||
|
||||
return jsonify(data)
|
||||
|
||||
|
||||
############################################### Partitions ############################################################
|
||||
@ -467,15 +483,30 @@ def partition(formsemestre_id: int):
|
||||
return error_response(501, message="Not implemented")
|
||||
|
||||
|
||||
@bp.route(
|
||||
"/partitions/formsemestre/<int:formsemestre_id>/groups/group_ids?with_codes=&all_groups=&etat=",
|
||||
methods=["GET"],
|
||||
)
|
||||
def groups(formsemestre_id: int, group_ids: int):
|
||||
# @bp.route(
|
||||
# "/partitions/formsemestre/<int:formsemestre_id>/groups/group_ids?with_codes=&all_groups=&etat=",
|
||||
# methods=["GET"],
|
||||
# )
|
||||
@bp.route("/partitions/groups/<int:group_id>", methods=["GET"])
|
||||
@bp.route("/partitions/groups/<int:group_id>/etat/<string:etat>", methods=["GET"])
|
||||
def etud_in_group(group_id: int, etat=None):
|
||||
"""
|
||||
Liste des étudiants dans un groupe
|
||||
"""
|
||||
return error_response(501, message="Not implemented")
|
||||
# fonction to use : get_group_members
|
||||
|
||||
if etat is None:
|
||||
try:
|
||||
data = get_group_members(group_id)
|
||||
except ValueError:
|
||||
return error_response(409, message="La requête ne peut être traitée en l’état actuel")
|
||||
else:
|
||||
try:
|
||||
data = get_group_members(group_id, etat)
|
||||
except ValueError:
|
||||
return error_response(409, message="La requête ne peut être traitée en l’état actuel")
|
||||
|
||||
return jsonify(data)
|
||||
|
||||
|
||||
@bp.route(
|
||||
@ -516,12 +547,13 @@ def evaluation_notes(evaluation_id: int):
|
||||
"""
|
||||
Liste des notes à partir de l'id d'une évaluation donnée
|
||||
"""
|
||||
notes = models.NotesNotes.query.filter_by(evaluation_id=evaluation_id).all()
|
||||
|
||||
data = [d.to_dict() for d in notes]
|
||||
# fonction to use : do_evaluation_get_all_notes
|
||||
try:
|
||||
data = do_evaluation_get_all_notes(evaluation_id)
|
||||
except ValueError:
|
||||
return error_response(409, message="La requête ne peut être traitée en l’état actuel")
|
||||
|
||||
return jsonify(data)
|
||||
# return error_response(501, message="Not implemented")
|
||||
|
||||
|
||||
@bp.route(
|
||||
@ -705,7 +737,7 @@ def abs_groupe_etat(
|
||||
Liste des absences d'un ou plusieurs groupes entre deux dates
|
||||
"""
|
||||
|
||||
# list_abs_date
|
||||
# list_abs_date<
|
||||
return error_response(501, message="Not implemented")
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user