Tie-in valve improvements (#13661)

Support (bool, something) pairs as tuples on python side.
Support custom outlet valve md
Add python test for custom outlet valve md
Use tie-in depth as default for custom valve md
Standalone valve creation and display updates
Update MSW valve export
Add valve open/shut flag.
Add python examples
This commit is contained in:
JJ authored and GitHub committed 2026-03-06 12:01:14 +01:00
1 parent f47de8457c
commit 24be78f105
34 files changed
+1139 -157

No files matched your search

@@ -45,6 +45,7 @@
#include "RimProject.h"
#include "RimStimPlanModelCollection.h"
#include "RimTools.h"
#include "RimValveCollection.h"
#include "RimWellEventTimeline.h"
#include "RimWellIASettingsCollection.h"
#include "RimWellLogChannel.h"
@@ -61,6 +62,7 @@
#include "RiuMainWindow.h"
#include "cafPdmFieldScriptingCapability.h"
#include "cafPdmObjectScriptingCapability.h"
#include "cafPdmUiTreeAttributes.h"
#include "cafPdmUiTreeOrdering.h"
#include "cafPdmUiTreeViewEditor.h"
@@ -148,7 +150,7 @@ RimWellPath::RimWellPath()
m_wellPathAttributes = new RimWellPathAttributeCollection;
m_wellPathAttributes->uiCapability()->setUiTreeHidden( true );
CAF_PDM_InitFieldNoDefault( &m_wellPathTieIn, "WellPathTieIn", "well Path Tie-In" );
CAF_PDM_InitFieldNoDefault( &m_wellPathTieIn, "WellPathTieIn", "Well Path Tie-In" );
m_wellPathTieIn = new RimWellPathTieIn;
m_wellPathTieIn->connectWellPaths( nullptr, this, 0.0 );
@@ -282,6 +284,16 @@ RimPerforationCollection* RimWellPath::perforationIntervalCollection()
return m_completions->perforationCollection();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimValveCollection* RimWellPath::valveCollection() const
{
CVF_ASSERT( m_completions );
return m_completions->valveCollection();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@@ -415,7 +427,7 @@ const RigWellPath* RimWellPath::wellPathGeometry() const
//--------------------------------------------------------------------------------------------------
double RimWellPath::startMD() const
{
if ( wellPathGeometry() )
if ( wellPathGeometry() && wellPathGeometry()->measuredDepths().size() > 0 )
{
return wellPathGeometry()->measuredDepths().front();
}
@@ -427,7 +439,7 @@ double RimWellPath::startMD() const
//--------------------------------------------------------------------------------------------------
double RimWellPath::endMD() const
{
if ( wellPathGeometry() )
if ( wellPathGeometry() && wellPathGeometry()->measuredDepths().size() > 0 )
{
return wellPathGeometry()->measuredDepths().back();
}
@@ -773,7 +785,10 @@ void RimWellPath::defineUiTreeOrdering( caf::PdmUiTreeOrdering& uiTreeOrdering,
{
uiTreeOrdering.add( m_completionSettings() );
}
if ( m_completions->valveCollection()->hasValves() )
{
uiTreeOrdering.add( m_completions->valveCollection() );
}
if ( m_completions->fishbonesCollection()->hasFishbones() )
{
uiTreeOrdering.add( m_completions->fishbonesCollection() );