From 103d22e2cab07e390f61eae8b419ba692562d78d Mon Sep 17 00:00:00 2001 From: Joseph Garrone Date: Thu, 28 Jan 2021 13:53:51 +0100 Subject: [PATCH] Fix ununcheckables fields --- .../catalogue-navigation/leaf/deploiement/nouveau-service.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/js/components/my-lab/catalogue/catalogue-navigation/leaf/deploiement/nouveau-service.tsx b/src/js/components/my-lab/catalogue/catalogue-navigation/leaf/deploiement/nouveau-service.tsx index b0c699dbf..c9f18e842 100644 --- a/src/js/components/my-lab/catalogue/catalogue-navigation/leaf/deploiement/nouveau-service.tsx +++ b/src/js/components/my-lab/catalogue/catalogue-navigation/leaf/deploiement/nouveau-service.tsx @@ -170,12 +170,12 @@ export const NouveauService: React.FC = ({ queryParams ]); - const handlechangeField = (path: string) => (value: string) => { + const handlechangeField = (path: string) => (value: any) => { setFieldsValues({ ...fieldsValues, [path]: (()=>{ switch(typeof fieldsValues[path]){ - case "boolean": return value === "true"; + case "boolean": return value; case "number": return Number.parseFloat(value); default: return value; }