Add well target generator cases to RimProject::allCases.

This commit is contained in:
Kristian Bendiksen 2024-12-20 13:13:31 +01:00
parent d1aec2f1cb
commit 1d552ea77d
5 changed files with 26 additions and 1 deletions

View File

@ -116,6 +116,14 @@ std::vector<RimEclipseCase*> RimEclipseCaseEnsemble::cases() const
return m_caseCollection->reservoirs.childrenByType(); return m_caseCollection->reservoirs.childrenByType();
} }
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::vector<RimWellTargetCandidatesGenerator*> RimEclipseCaseEnsemble::wellTargetsGenerators() const
{
return m_wellTargetGenerators.childrenByType();
}
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------
/// ///
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------

View File

@ -56,7 +56,8 @@ public:
RimEclipseViewCollection* viewCollection() const; RimEclipseViewCollection* viewCollection() const;
void addWellTargetsGenerator( RimWellTargetCandidatesGenerator* generator ); void addWellTargetsGenerator( RimWellTargetCandidatesGenerator* generator );
std::vector<RimWellTargetCandidatesGenerator*> wellTargetsGenerators() const;
void addStatisticsContourMap( RimStatisticsContourMap* statisticsContourMap ); void addStatisticsContourMap( RimStatisticsContourMap* statisticsContourMap );

View File

@ -102,6 +102,7 @@
#include "RimWellPath.h" #include "RimWellPath.h"
#include "RimWellPathCollection.h" #include "RimWellPathCollection.h"
#include "RimWellTargetCandidatesGenerator.h"
#include "VerticalFlowPerformance/RimVfpDataCollection.h" #include "VerticalFlowPerformance/RimVfpDataCollection.h"
#include "VerticalFlowPerformance/RimVfpPlotCollection.h" #include "VerticalFlowPerformance/RimVfpPlotCollection.h"
@ -605,6 +606,11 @@ std::vector<RimCase*> RimProject::allGridCases() const
{ {
cases.push_back( acase ); cases.push_back( acase );
} }
for ( RimWellTargetCandidatesGenerator* generator : ensemble->wellTargetsGenerators() )
{
if ( auto ensembleStatisticsCase = generator->ensembleStatisticsCase() ) cases.push_back( ensembleStatisticsCase );
}
} }
RimGeoMechModels* geomModels = oilField->geoMechModels(); RimGeoMechModels* geomModels = oilField->geoMechModels();

View File

@ -423,3 +423,11 @@ void RimWellTargetCandidatesGenerator::updateResultDefinition()
RimEclipseCase* eclipseCase = firstCase(); RimEclipseCase* eclipseCase = firstCase();
if ( eclipseCase ) m_resultDefinition->setEclipseCase( eclipseCase ); if ( eclipseCase ) m_resultDefinition->setEclipseCase( eclipseCase );
} }
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimEclipseCase* RimWellTargetCandidatesGenerator::ensembleStatisticsCase() const
{
return m_ensembleStatisticsCase;
}

View File

@ -42,6 +42,8 @@ public:
void updateResultDefinition(); void updateResultDefinition();
RimEclipseCase* ensembleStatisticsCase() const;
protected: protected:
void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override; void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;
void defineEditorAttribute( const caf::PdmFieldHandle* field, QString uiConfigName, caf::PdmUiEditorAttribute* attribute ) override; void defineEditorAttribute( const caf::PdmFieldHandle* field, QString uiConfigName, caf::PdmUiEditorAttribute* attribute ) override;