mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-15 01:42:13 -05:00
#9913 Fix import of RFT pressure/depth
This commit is contained in:
1 parent
4953b6abad
commit
07a4c13dd4
2 files changed
+9
-6
No files matched your search
@@ -51,7 +51,8 @@ std::pair<std::vector<RigPressureDepthData>, QString> RifPressureDepthTextFileRe
|
||||
QString line = in.readLine();
|
||||
if ( isHeaderLine( line ) )
|
||||
{
|
||||
QStringList headerValues = RifFileParseTools::splitLineAndTrim( line, separator );
|
||||
bool skipEmptyParts = true;
|
||||
QStringList headerValues = RifFileParseTools::splitLineAndTrim( line, separator, skipEmptyParts );
|
||||
RigPressureDepthData data;
|
||||
data.setWellName( headerValues[1].replace( "'", "" ) );
|
||||
items.push_back( data );
|
||||
@@ -125,7 +126,8 @@ bool RifPressureDepthTextFileReader::isUnitsLine( const QString& line )
|
||||
std::optional<std::pair<double, double>> RifPressureDepthTextFileReader::parseDataLine( const QString& line )
|
||||
{
|
||||
// Expect two data values separated by one space
|
||||
QStringList values = RifFileParseTools::splitLineAndTrim( line, " " );
|
||||
bool skipEmptyParts = true;
|
||||
QStringList values = RifFileParseTools::splitLineAndTrim( line, " ", skipEmptyParts );
|
||||
if ( values.size() != 2 ) return {};
|
||||
|
||||
// First value is pressure
|
||||
@@ -146,7 +148,8 @@ std::optional<std::pair<double, double>> RifPressureDepthTextFileReader::parseDa
|
||||
std::optional<QDateTime> RifPressureDepthTextFileReader::parseDateLine( const QString& line )
|
||||
{
|
||||
// Expect two data values separated by one space
|
||||
QStringList values = RifFileParseTools::splitLineAndTrim( line, " " );
|
||||
bool skipEmptyParts = true;
|
||||
QStringList values = RifFileParseTools::splitLineAndTrim( line, " ", skipEmptyParts );
|
||||
if ( values.size() != 2 ) return {};
|
||||
|
||||
CAF_ASSERT( values[0] == "DATE" );
|
||||
|
||||
Reference in new issue
Block a user