diff --git a/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.cpp b/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.cpp index c53777a430..efb3fe5eb0 100644 --- a/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.cpp +++ b/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.cpp @@ -69,6 +69,7 @@ RicfExportWellPathCompletions::RicfExportWellPathCompletions() "", "" ); + CAF_PDM_InitScriptableField( &m_includeMsw, "includeMsw", true, "Export Multi Segment Well Model", "", "", "" ); CAF_PDM_InitScriptableField( &m_useLateralNTG, "useNtgHorizontally", false, "Use NTG Horizontally", "", "", "" ); CAF_PDM_InitScriptableField( &m_includePerforations, "includePerforations", true, "Include Perforations", "", "", "" ); CAF_PDM_InitScriptableField( &m_includeFishbones, "includeFishbones", true, "Include Fishbones", "", "", "" ); @@ -110,6 +111,16 @@ RicfExportWellPathCompletions::RicfExportWellPathCompletions() "", "", "" ); + + CAF_PDM_InitScriptableField( &m_exportWelspec, "exportWelspec", true, "Export WELSPEC keyword", "", "", "" ); + CAF_PDM_InitScriptableField( &m_completionWelspecAfterMainBore, + "completionWelspecAfterMainBore", + false, + "WELSEGS per Completion Type", + "", + "", + "" ); + CAF_PDM_InitScriptableField( &m_customFileName, "customFileName", QString(), "Custom Filename", "", "", "" ); } //-------------------------------------------------------------------------------------------------- @@ -139,6 +150,7 @@ caf::PdmScriptResponse RicfExportWellPathCompletions::execute() exportSettings.transScalingWBHPSource = m_transScalingInitialWBHP; exportSettings.transScalingWBHP = m_transScalingWBHP; + exportSettings.includeMsw = m_includeMsw; exportSettings.useLateralNTG = m_useLateralNTG; exportSettings.includePerforations = m_includePerforations; exportSettings.includeFishbones = m_includeFishbones; @@ -147,6 +159,10 @@ caf::PdmScriptResponse RicfExportWellPathCompletions::execute() exportSettings.setCombinationMode( m_combinationMode() ); + exportSettings.setExportWelspec( m_exportWelspec ); + exportSettings.setExportCompletionWelspecAfterMainBore( m_completionWelspecAfterMainBore ); + exportSettings.setCustomFileName( m_customFileName ); + { auto eclipseCase = TOOLS::caseFromId( m_caseId() ); if ( !eclipseCase ) diff --git a/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.h b/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.h index 82e30f50de..983bb4ca71 100644 --- a/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.h +++ b/ApplicationLibCode/CommandFileInterface/RicfExportWellPathCompletions.h @@ -53,9 +53,17 @@ private: caf::PdmField m_transScalingInitialWBHP; caf::PdmField m_transScalingWBHP; + caf::PdmField m_includeMsw; caf::PdmField m_useLateralNTG; caf::PdmField m_includePerforations; caf::PdmField m_includeFishbones; caf::PdmField m_includeFractures; caf::PdmField m_excludeMainBoreForFishbones; + + // This is handeled by RicfCommandFileExecutor::exportDataSouceAsComment() + // caf::PdmField m_exportDataSourceAsComment; + + caf::PdmField m_exportWelspec; + caf::PdmField m_completionWelspecAfterMainBore; + caf::PdmField m_customFileName; }; diff --git a/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.cpp b/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.cpp index 653582a1af..117f693c05 100644 --- a/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.cpp +++ b/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.cpp @@ -213,6 +213,14 @@ bool RicExportCompletionDataSettingsUi::exportDataSourceAsComment() const return m_exportDataSourceAsComment; } +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +void RicExportCompletionDataSettingsUi::setExportWelspec( bool enable ) +{ + m_exportWelspec = enable; +} + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- @@ -221,6 +229,14 @@ bool RicExportCompletionDataSettingsUi::exportWelspec() const return m_exportWelspec; } +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +void RicExportCompletionDataSettingsUi::setExportCompletionWelspecAfterMainBore( bool enable ) +{ + m_completionWelspecAfterMainBore = enable; +} + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- @@ -229,6 +245,15 @@ bool RicExportCompletionDataSettingsUi::exportCompletionWelspecAfterMainBore() c return m_completionWelspecAfterMainBore(); } +//-------------------------------------------------------------------------------------------------- +/// +//-------------------------------------------------------------------------------------------------- +void RicExportCompletionDataSettingsUi::setCustomFileName( const QString& fileName ) +{ + m_useCustomFileName = !fileName.isEmpty(); + m_customFileName = fileName; +} + //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- diff --git a/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.h b/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.h index 75d0da3963..f9dc4878c1 100644 --- a/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.h +++ b/ApplicationLibCode/Commands/CompletionExportCommands/RicExportCompletionDataSettingsUi.h @@ -89,17 +89,23 @@ public: void showForWellPath(); void setCombinationMode( CombinationMode combinationMode ); - void setExportDataSourceAsComment( bool enable ); void showFractureInUi( bool enable ); void showPerforationsInUi( bool enable ); void showFishbonesInUi( bool enable ); bool reportCompletionsTypesIndividually() const; + + void setExportDataSourceAsComment( bool enable ); bool exportDataSourceAsComment() const; + + void setExportWelspec( bool enable ); bool exportWelspec() const; + + void setExportCompletionWelspecAfterMainBore( bool enable ); bool exportCompletionWelspecAfterMainBore() const; + void setCustomFileName( const QString& fileName ); QString customFileName() const; void fieldChangedByUi( const caf::PdmFieldHandle* changedField, const QVariant& oldValue, const QVariant& newValue ) override;