[arvados-workbench2] updated: 2.7.0-216-g6001b0f2

git repository hosting git at public.arvados.org
Mon Nov 27 15:05:55 UTC 2023


Summary of changes:
 src/views-components/data-explorer/data-explorer.tsx | 16 ++++++++--------
 src/views-components/details-panel/details-panel.tsx |  4 ++--
 2 files changed, 10 insertions(+), 10 deletions(-)

       via  6001b0f21e5c27fe41c84b4745b09bc7536b2357 (commit)
      from  bead3b2896eaaceb9b9a3c805d40e8048c93b218 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 6001b0f21e5c27fe41c84b4745b09bc7536b2357
Author: Lisa Knox <lisaknox83 at gmail.com>
Date:   Mon Nov 27 10:05:50 2023 -0500

    21128: fixed details panel crash Arvados-DCO-1.1-Signed-off-by: Lisa Knox <lisa.knox at curii.com>

diff --git a/src/views-components/data-explorer/data-explorer.tsx b/src/views-components/data-explorer/data-explorer.tsx
index 6c9aeb06..2e316f68 100644
--- a/src/views-components/data-explorer/data-explorer.tsx
+++ b/src/views-components/data-explorer/data-explorer.tsx
@@ -22,14 +22,14 @@ interface Props {
     extractKey?: (item: any) => React.Key;
 }
 
-const mapStateToProps = (state: RootState, { id }: Props) => {
-    const progress = state.progressIndicator.find(p => p.id === id);
-    const dataExplorerState = getDataExplorer(state.dataExplorer, id);
-    const currentRoute = state.router.location ? state.router.location.pathname : "";
+const mapStateToProps = ({ progressIndicator, dataExplorer, router, multiselect, detailsPanel, properties}: RootState, { id }: Props) => {
+    const progress = progressIndicator.find(p => p.id === id);
+    const dataExplorerState = getDataExplorer(dataExplorer, id);
+    const currentRoute = router.location ? router.location.pathname : "";
     const currentRefresh = localStorage.getItem(LAST_REFRESH_TIMESTAMP) || "";
-    const isDetailsResourceChecked = state.multiselect.checkedList[state.detailsPanel.resourceUuid]
-    const currentItemUuid = currentRoute === "/workflows" ? state.properties.workflowPanelDetailsUuid : isDetailsResourceChecked ? state.detailsPanel.resourceUuid : state.multiselect.selectedUuid;
-    const isMSToolbarVisible = state.multiselect.isVisible;
+    const isDetailsResourceChecked = multiselect.checkedList[detailsPanel.resourceUuid]
+    const currentItemUuid = currentRoute === "/workflows" ? properties.workflowPanelDetailsUuid : isDetailsResourceChecked ? detailsPanel.resourceUuid : multiselect.selectedUuid;
+    const isMSToolbarVisible = multiselect.isVisible;
     return {
         ...dataExplorerState,
         working: !!progress?.working,
@@ -38,7 +38,7 @@ const mapStateToProps = (state: RootState, { id }: Props) => {
         paperKey: currentRoute,
         currentItemUuid,
         isMSToolbarVisible,
-        checkedList: state.multiselect.checkedList,
+        checkedList: multiselect.checkedList,
     };
 };
 
diff --git a/src/views-components/details-panel/details-panel.tsx b/src/views-components/details-panel/details-panel.tsx
index 672d678f..39cb78aa 100644
--- a/src/views-components/details-panel/details-panel.tsx
+++ b/src/views-components/details-panel/details-panel.tsx
@@ -86,8 +86,8 @@ const getItem = (res: DetailsResource): DetailsData => {
 const mapStateToProps = ({ auth, detailsPanel, resources, collectionPanelFiles, multiselect, router }: RootState) => {
     const isDetailsResourceChecked = multiselect.checkedList[detailsPanel.resourceUuid]
     const currentRoute = router.location ? router.location.pathname : "";
-    const currentItemUuid = isDetailsResourceChecked ? detailsPanel.resourceUuid : multiselect.selectedUuid || currentRoute.split('/')[2];
-    const resource = getResource(currentItemUuid)(resources) as DetailsResource | undefined || '';
+    const currentItemUuid = isDetailsResourceChecked ? detailsPanel.resourceUuid : multiselect.selectedUuid ? multiselect.selectedUuid : currentRoute.split('/')[2];
+    const resource = getResource(currentItemUuid)(resources) as DetailsResource | undefined;
     const file = resource
         ? undefined
         : getNode(detailsPanel.resourceUuid)(collectionPanelFiles);

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list