From 1a6aa269ee772c2fa1132286fe39669a11319d30 Mon Sep 17 00:00:00 2001 From: Emmanuel Viennet Date: Sat, 25 Feb 2023 11:33:28 +0100 Subject: [PATCH] Fix: tri tables --- app/tables/recap.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/tables/recap.py b/app/tables/recap.py index 9704ee55..cf2a8533 100644 --- a/app/tables/recap.py +++ b/app/tables/recap.py @@ -108,9 +108,9 @@ class TableRecap(tb.Table): # Tri par rang croissant if not res.formsemestre.block_moyenne_generale: - self.sort_rows(key=lambda row: row.rang_order) + self.sort_rows(key=lambda row: row.rang_order or 10000000) else: - self.sort_rows(key=lambda row: row.nb_ues_validables, reverse=True) + self.sort_rows(key=lambda row: row.nb_ues_validables or 0, reverse=True) # Lignes footer (min, max, ects, apo, ...) self.add_bottom_rows(ues_sans_bonus)