From 767639a202f74d9db033334aa726c42aee135759 Mon Sep 17 00:00:00 2001 From: Elias Bruvik Date: Fri, 12 Jan 2024 12:38:12 +0000 Subject: [PATCH] FIX-2204 filter out indexCurve --- .../ContextMenus/LogCurveInfoContextMenu.tsx | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/Src/WitsmlExplorer.Frontend/components/ContextMenus/LogCurveInfoContextMenu.tsx b/Src/WitsmlExplorer.Frontend/components/ContextMenus/LogCurveInfoContextMenu.tsx index 8072001fa..55c088e75 100644 --- a/Src/WitsmlExplorer.Frontend/components/ContextMenus/LogCurveInfoContextMenu.tsx +++ b/Src/WitsmlExplorer.Frontend/components/ContextMenus/LogCurveInfoContextMenu.tsx @@ -57,6 +57,10 @@ const LogCurveInfoContextMenu = ( selectedServer, servers } = props; + const checkedLogCurveInfoRowsWithoutIndexCurve = + checkedLogCurveInfoRows.filter( + (lc) => lc.mnemonic !== selectedLog.indexCurve + ); const onClickOpen = () => { dispatchOperation({ type: OperationType.HideContextMenu }); @@ -111,10 +115,11 @@ const LogCurveInfoContextMenu = ( }; const toDelete = createComponentReferences( - checkedLogCurveInfoRows.map((lc) => lc.mnemonic), + checkedLogCurveInfoRowsWithoutIndexCurve.map((lc) => lc.mnemonic), selectedLog, ComponentType.Mnemonic ); + return ( , @@ -210,9 +215,8 @@ const LogCurveInfoContextMenu = ( , Analyze gaps