diff --git a/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.cpp b/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.cpp index 3f82c2f5b7..3a21875d28 100644 --- a/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.cpp +++ b/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.cpp @@ -479,10 +479,9 @@ std::pair RifFaultReactivationModelExporter::printSteps( std: for ( int i = 0; i < static_cast( timeSteps.size() ); i++ ) { std::string stepNum = std::to_string( i + 1 ); - std::string stepName = "Step-" + stepNum; + std::string stepName = timeSteps[i].toString( "yyyy-MM-dd" ).toStdString(); RifInpExportTools::printComment( stream, "----------------------------------------------------------------" ); RifInpExportTools::printSectionComment( stream, "STEP: " + stepName ); - RifInpExportTools::printComment( stream, "Time step: " + timeSteps[i].toString().toStdString() ); RifInpExportTools::printHeading( stream, "Step, name=" + stepName + ", nlgeom=NO" ); @@ -495,7 +494,7 @@ std::pair RifFaultReactivationModelExporter::printSteps( std: RifInpExportTools::printSectionComment( stream, "BOUNDARY CONDITIONS" ); // Export the pore pressure to a separate inp file for each step - std::string fileName = createFileName( "PORE_PRESSURE", timeSteps[i], stepName ); + std::string fileName = createFileName( "PORE_PRESSURE", stepName ); std::string filePath = createFilePath( exportDirectory, fileName ); bool isOk = @@ -511,7 +510,7 @@ std::pair RifFaultReactivationModelExporter::printSteps( std: RifInpExportTools::printSectionComment( stream, "TEMPERATURE" ); // Export the pore pressure to a separate inp file for each step - std::string fileName = createFileName( "TEMPERATURE", timeSteps[i], stepName ); + std::string fileName = createFileName( "TEMPERATURE", stepName ); std::string filePath = createFilePath( exportDirectory, fileName ); bool isOk = writePropertyToFile( model, dataAccess, RimFaultReactivation::Property::Temperature, i, filePath, partNames, "" ); @@ -601,13 +600,9 @@ std::pair //-------------------------------------------------------------------------------------------------- /// //-------------------------------------------------------------------------------------------------- -std::string RifFaultReactivationModelExporter::createFileName( const std::string& title, const QDateTime& dateTime, const std::string& stepName ) +std::string RifFaultReactivationModelExporter::createFileName( const std::string& title, const std::string& stepName ) { - return QString( "%1_DATE_%2_%3.inp" ) - .arg( QString::fromStdString( title ) ) - .arg( dateTime.toString( "yyyyMMdd" ) ) - .arg( QString::fromStdString( stepName ) ) - .toStdString(); + return QString( "%1_%2.inp" ).arg( QString::fromStdString( title ) ).arg( QString::fromStdString( stepName ) ).toStdString(); } //-------------------------------------------------------------------------------------------------- diff --git a/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.h b/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.h index 9138bd0b44..70d5ceecaf 100644 --- a/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.h +++ b/ApplicationLibCode/FileInterface/RifFaultReactivationModelExporter.h @@ -91,7 +91,7 @@ private: const std::map& partNames, const std::string& additionalData ); - static std::string createFileName( const std::string& title, const QDateTime& dateTime, const std::string& stepName ); + static std::string createFileName( const std::string& title, const std::string& stepName ); static std::string createFilePath( const std::string& dir, const std::string& fileName ); };