From e611fa4bfcd778ec9122587c5bd53dd6d159d6a7 Mon Sep 17 00:00:00 2001 From: Emmanuel Viennet Date: Mon, 5 Feb 2024 08:46:21 +0100 Subject: [PATCH] =?UTF-8?q?Fix:=20cr=C3=A9ation=201ere=20=C3=A9valuation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/scodoc/sco_evaluation_edit.py | 3 ++- sco_version.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/app/scodoc/sco_evaluation_edit.py b/app/scodoc/sco_evaluation_edit.py index b3277f73a..07718708c 100644 --- a/app/scodoc/sco_evaluation_edit.py +++ b/app/scodoc/sco_evaluation_edit.py @@ -90,10 +90,11 @@ def evaluation_create_form( # création nouvel if moduleimpl_id is None: raise ValueError("missing moduleimpl_id parameter") + numeros = [(e.numero or 0) for e in modimpl.evaluations] initvalues = { "jour": time.strftime("%d/%m/%Y", time.localtime()), "note_max": 20, - "numero": max(e.numero or 0 for e in modimpl.evaluations) + 1, + "numero": (max(numeros) + 1) if numeros else 0, "publish_incomplete": is_malus, "visibulletin": 1, } diff --git a/sco_version.py b/sco_version.py index 131fa66cf..a7cb166cf 100644 --- a/sco_version.py +++ b/sco_version.py @@ -1,7 +1,7 @@ # -*- mode: python -*- # -*- coding: utf-8 -*- -SCOVERSION = "9.6.931" +SCOVERSION = "9.6.932" SCONAME = "ScoDoc"