@gridsuite/commons-ui 0.196.0 → 0.197.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -25,8 +25,12 @@ const useCsvExport = () => {
|
|
|
25
25
|
if (params.column.getColId() === "limitName") {
|
|
26
26
|
return formatNAValue(params.value);
|
|
27
27
|
}
|
|
28
|
-
if (
|
|
29
|
-
|
|
28
|
+
if (typeof params.value === "number") {
|
|
29
|
+
const fractionDigits = params.column.getColDef()?.cellRendererParams?.fractionDigits ?? params.column.getColDef()?.context?.fractionDigits;
|
|
30
|
+
const roundedValue = fractionDigits != null && !Number.isNaN(params.value) ? params.value.toFixed(fractionDigits) : params.value;
|
|
31
|
+
if (props.language === LANG_FRENCH) {
|
|
32
|
+
return roundedValue.toString().replace(".", ",");
|
|
33
|
+
}
|
|
30
34
|
}
|
|
31
35
|
return params.value;
|
|
32
36
|
};
|