Skip to content

Commit

Permalink
Fix Import Summary Cases Recursively
Browse files Browse the repository at this point in the history
Make sure that the loaded summary cases are added to the project.
  • Loading branch information
magnesj committed Sep 15, 2023
1 parent 5add6f5 commit bdcd256
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions ApplicationLibCode/Commands/RicImportSummaryCasesFeature.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,11 @@ void RicImportSummaryCasesFeature::onActionTriggered( bool isChecked )
QStringList fileNames = result.files;
RiaDefines::FileType fileType = RicRecursiveFileSearchDialog::mapSummaryFileType( result.fileType );

std::vector<RimSummaryCase*> cases;
if ( fileNames.isEmpty() ) return;

if ( !fileNames.isEmpty() )
{
CreateConfig createConfig{ .fileType = fileType, .ensembleOrGroup = false, .allowDialogs = true };
auto [isOk, cases] = createSummaryCasesFromFiles( fileNames, createConfig );
}
CreateConfig createConfig{ .fileType = fileType, .ensembleOrGroup = false, .allowDialogs = true };
auto [isOk, cases] = createSummaryCasesFromFiles( fileNames, createConfig );
if ( !isOk ) return;

addSummaryCases( cases );
if ( !cases.empty() )
Expand Down

0 comments on commit bdcd256

Please sign in to comment.