From 1427b9010e3d9252eac05770429033098070520b Mon Sep 17 00:00:00 2001 From: Sylvain Kieffer Date: Fri, 4 Oct 2024 11:35:59 +0200 Subject: [PATCH] Permettre d'utiliser les built-ins Freemarker dans les templates #201 --- .../esup_stage/controller/TemplateConventionController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/esup_portail/esup_stage/controller/TemplateConventionController.java b/src/main/java/org/esup_portail/esup_stage/controller/TemplateConventionController.java index 3a576bc3..d370b9b6 100644 --- a/src/main/java/org/esup_portail/esup_stage/controller/TemplateConventionController.java +++ b/src/main/java/org/esup_portail/esup_stage/controller/TemplateConventionController.java @@ -145,7 +145,7 @@ private List extractChamps(String texte) { } private void checkChamp(List champs, String champ) { - if (champs.stream().noneMatch(c -> c.getCode().equals(champ))) { + if (champs.stream().noneMatch(c -> c.getCode().equals(champ.split("\\?")[0]))) { throw new AppException(HttpStatus.BAD_REQUEST, "Le champ personnalisé ${" + champ + "} n'existe pas"); } }