#11636 Fix missing well path creation when importing LAS file without a well path file

Fixes #11636.
This commit is contained in:
Kristian Bendiksen
2024-08-23 11:46:33 +02:00
committed by Magne Sjaastad
parent 1b509c0384
commit c322ba62bb
2 changed files with 14 additions and 2 deletions

View File

@@ -152,10 +152,19 @@ bool RimWellLogLasFile::readFile( QString* errorMessage )
m_wellLogChannels.push_back( wellLog );
}
auto wellPath = firstAncestorOrThisOfType<RimFileWellPath>();
auto fileWellPath = firstAncestorOrThisOfType<RimFileWellPath>();
if ( fileWellPath )
{
if ( fileWellPath->filePath().isEmpty() ) // Has dummy wellpath
{
fileWellPath->setName( m_wellName );
}
}
auto wellPath = firstAncestorOrThisOfType<RimWellPath>();
if ( wellPath )
{
if ( wellPath->filePath().isEmpty() ) // Has dummy wellpath
if ( wellPath->name().isEmpty() )
{
wellPath->setName( m_wellName );
}