From aa095eae08e433b757508aa98ea2d5ed7feb8082 Mon Sep 17 00:00:00 2001 From: Manus Date: Thu, 11 Jun 2026 09:31:03 +0000 Subject: [PATCH] =?UTF-8?q?Checkpoint:=20La=20colonne=20Code=20est=20maint?= =?UTF-8?q?enant=20cliquable=20dans=20la=20vue=20=C3=89tablissements=20OPE?= =?UTF-8?q?X=20:=20clic=20pour=20trier=20par=20code=20croissant/d=C3=A9cro?= =?UTF-8?q?issant.=20Le=20tri=20par=20code=20est=20aussi=20le=20tri=20par?= =?UTF-8?q?=20d=C3=A9faut=20(quand=20aucune=20autre=20colonne=20n'est=20s?= =?UTF-8?q?=C3=A9lectionn=C3=A9e).=20Les=20colonnes=20=C3=89tablissement?= =?UTF-8?q?=20et=20Total=20restent=20triables=20comme=20avant.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- client/src/pages/DsiOpex.tsx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/client/src/pages/DsiOpex.tsx b/client/src/pages/DsiOpex.tsx index 159d307..49c4131 100644 --- a/client/src/pages/DsiOpex.tsx +++ b/client/src/pages/DsiOpex.tsx @@ -1203,6 +1203,8 @@ export default function DsiOpex() { const arr = [...filteredEtabs]; if (sortCol === 'total') arr.sort((a, b) => sortDir === 'asc' ? a.total - b.total : b.total - a.total); else if (sortCol === 'nom') arr.sort((a, b) => sortDir === 'asc' ? a.nom.localeCompare(b.nom) : b.nom.localeCompare(a.nom)); + else if (sortCol === 'code') arr.sort((a, b) => sortDir === 'asc' ? a.code.localeCompare(b.code) : b.code.localeCompare(a.code)); + else arr.sort((a, b) => a.code.localeCompare(b.code)); // tri par défaut : code croissant return arr; }, [filteredEtabs, sortCol, sortDir]); @@ -1773,7 +1775,9 @@ export default function DsiOpex() { - +
Code + +