Skip to content

Commit

Permalink
datanode update data (#952)
Browse files Browse the repository at this point in the history
* datanode update data
resolves #950

* format

---------

Co-authored-by: Fred Lefévère-Laoide <[email protected]>
  • Loading branch information
FredLL-Avaiga and Fred Lefévère-Laoide authored Mar 9, 2024
1 parent ea8f892 commit fbca22d
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions frontend/taipy/src/DataNodeViewer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -303,11 +303,8 @@ const DataNodeViewer = (props: DataNodeViewerProps) => {
}
return false;
});
setDataRequested((req) => {
if (!isNewDn) {
return req;
}
if (req && tabValue == TabValues.Data) {
setDataRequested(() => {
if (tabValue == TabValues.Data) {
dispatch(
createSendActionNameAction(id, module, props.onIdSelect, {
data_id: newDnId,
Expand Down Expand Up @@ -420,7 +417,7 @@ const DataNodeViewer = (props: DataNodeViewerProps) => {

// Datanode data
const dtType = props.data && props.data[DatanodeDataProps.type];
const dtValue = (props.data && props.data[DatanodeDataProps.value]) ?? ((dtType == "float") ? null : undefined);
const dtValue = (props.data && props.data[DatanodeDataProps.value]) ?? (dtType == "float" ? null : undefined);
const dtTabular = (props.data && props.data[DatanodeDataProps.tabular]) ?? false;
const dtError = props.data && props.data[DatanodeDataProps.error];
const [dataValue, setDataValue] = useState<RowValue | Date>();
Expand Down

0 comments on commit fbca22d

Please sign in to comment.