#5917 Export Completion: Avoid overwrite of export completion well name

This commit is contained in:
Magne Sjaastad
2020-05-22 12:25:25 +02:00
parent ff90ae5704
commit 4a8aa6ced1
5 changed files with 25 additions and 7 deletions

View File

@@ -139,7 +139,7 @@ void RimFileWellPath::defineUiOrdering( QString uiConfigName, caf::PdmUiOrdering
//--------------------------------------------------------------------------------------------------
/// Read JSON or ascii file containing well path data
//--------------------------------------------------------------------------------------------------
bool RimFileWellPath::readWellPathFile( QString* errorMessage, RifWellPathImporter* wellPathImporter )
bool RimFileWellPath::readWellPathFile( QString* errorMessage, RifWellPathImporter* wellPathImporter, bool setWellNameForExport )
{
if ( caf::Utils::fileExists( this->filePath() ) )
{
@@ -150,7 +150,15 @@ bool RimFileWellPath::readWellPathFile( QString* errorMessage, RifWellPathImport
wellPathImporter->readWellMetaData( this->filePath(), m_wellPathIndexInFile() );
// General well info
setName( wellData.m_name );
if ( setWellNameForExport )
{
setName( wellData.m_name );
}
else
{
setNameNoUpdateOfExportName( wellData.m_name );
}
id = wellMetaData.m_id;
sourceSystem = wellMetaData.m_sourceSystem;
utmZone = wellMetaData.m_utmZone;