From ce78a6683ab8648ed90e944cd23ed7c01205fce6 Mon Sep 17 00:00:00 2001 From: Aijana Schumann Date: Fri, 13 Mar 2020 10:39:11 +0100 Subject: Fix odlux bugs Fix help and about app not scrollable Fix filter hiding and showing without user interaction and default sort in all tables Issue-ID: SDNC-1117 Signed-off-by: Aijana Schumann Change-Id: I5c6ff86c73a3b222a8d9022125454788496f6399 --- .../apps/connectApp/src/components/connectionStatusLog.tsx | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'sdnr/wt/odlux/apps/connectApp/src/components/connectionStatusLog.tsx') diff --git a/sdnr/wt/odlux/apps/connectApp/src/components/connectionStatusLog.tsx b/sdnr/wt/odlux/apps/connectApp/src/components/connectionStatusLog.tsx index ad7b247b0..96f6c8a6b 100644 --- a/sdnr/wt/odlux/apps/connectApp/src/components/connectionStatusLog.tsx +++ b/sdnr/wt/odlux/apps/connectApp/src/components/connectionStatusLog.tsx @@ -35,6 +35,9 @@ const ConnectionStatusTable = MaterialTable as MaterialTableCtorType; +let initialSorted = false; + + class ConnectionStatusLogComponent extends React.Component { render(): JSX.Element { return ( @@ -46,6 +49,15 @@ class ConnectionStatusLogComponent extends React.Component ); }; + + componentDidMount() { + if (!initialSorted) { + initialSorted = true; + this.props.connectionStatusLogActions.onHandleExplicitRequestSort("timestamp", "desc"); + } else { + this.props.connectionStatusLogActions.onRefresh(); + } + } } export const ConnectionStatusLog = connect(mapProps, mapDispatch)(ConnectionStatusLogComponent); -- cgit 1.2.3-korg