@m4l/components 9.3.29-JT19112025.beta.4 → 9.3.29-JT19112025.beta.6
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.
|
@@ -19,6 +19,7 @@ function CardDetails({
|
|
|
19
19
|
const { getLabel } = useModuleDictionary();
|
|
20
20
|
const { host_static_assets, environment_assets } = useEnvironment();
|
|
21
21
|
const { currentSize } = useComponentSize(size);
|
|
22
|
+
const currentRow = rows[rowIndex] || row;
|
|
22
23
|
const handleForceRefresh = useCallback(() => {
|
|
23
24
|
setRefreshCounter((prev) => prev + 1);
|
|
24
25
|
}, []);
|
|
@@ -56,7 +57,7 @@ function CardDetails({
|
|
|
56
57
|
if (modifiedColumn.renderEditCell && editingColumnKey === modifiedColumn.key) {
|
|
57
58
|
return /* @__PURE__ */ jsx(EditorCellWrapperStyled, { ownerState: { size }, children: modifiedColumn.renderEditCell({
|
|
58
59
|
column: originalColumn,
|
|
59
|
-
row,
|
|
60
|
+
row: currentRow,
|
|
60
61
|
rowIdx: index,
|
|
61
62
|
/**
|
|
62
63
|
* onRowChange es una función que se ejecuta cuando el usuario edita una celda.
|
|
@@ -70,6 +71,7 @@ function CardDetails({
|
|
|
70
71
|
indexes: [rowIndex],
|
|
71
72
|
column: originalColumn
|
|
72
73
|
});
|
|
74
|
+
handleForceRefresh();
|
|
73
75
|
}
|
|
74
76
|
},
|
|
75
77
|
onClose: () => setEditingColumnKey(null)
|
|
@@ -78,7 +80,7 @@ function CardDetails({
|
|
|
78
80
|
if (modifiedColumn.renderCell) {
|
|
79
81
|
const cellContent = modifiedColumn.renderCell({
|
|
80
82
|
column: modifiedColumn,
|
|
81
|
-
row,
|
|
83
|
+
row: currentRow,
|
|
82
84
|
rowIdx: index,
|
|
83
85
|
isCellSelected: false,
|
|
84
86
|
tabIndex: -1,
|
|
@@ -94,12 +96,13 @@ function CardDetails({
|
|
|
94
96
|
indexes: [rowIndex],
|
|
95
97
|
column: originalColumn
|
|
96
98
|
});
|
|
99
|
+
handleForceRefresh();
|
|
97
100
|
}
|
|
98
101
|
}
|
|
99
102
|
});
|
|
100
103
|
return /* @__PURE__ */ jsx(ValueColumnStyled, { variant: "body", color: "text.primary", children: cellContent });
|
|
101
104
|
}
|
|
102
|
-
const rawValue =
|
|
105
|
+
const rawValue = currentRow[modifiedColumn.key];
|
|
103
106
|
const isEmpty = rawValue === null || rawValue === void 0 || rawValue === "";
|
|
104
107
|
const isEditable = !!modifiedColumn.renderEditCell;
|
|
105
108
|
if (isEditable) {
|