mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-08 07:03:25 -06:00
#2007 RFT plot. Use central logic for date/time formatting.
This commit is contained in:
parent
8d96e9e35a
commit
5f39bc5c39
@ -1139,11 +1139,20 @@ void RimWellRftPlot::calculateValueOptionsForTimeSteps(const QString& wellName,
|
||||
}
|
||||
}
|
||||
|
||||
addTimeStepsToMap(m_timeStepsToAddresses, displayTimeStepsMap);
|
||||
|
||||
// Create vector of all time steps
|
||||
std::vector<QDateTime> allTimeSteps;
|
||||
for (const auto& timeStepPair : m_timeStepsToAddresses)
|
||||
{
|
||||
allTimeSteps.push_back(timeStepPair.first);
|
||||
}
|
||||
|
||||
auto dateFormatString = RimTools::createTimeFormatStringFromDates(allTimeSteps);
|
||||
for (const auto& timeStepPair : displayTimeStepsMap)
|
||||
{
|
||||
options.push_back(caf::PdmOptionItemInfo(timeStepPair.first.toString(RimTools::dateFormatString()), timeStepPair.first));
|
||||
options.push_back(caf::PdmOptionItemInfo(timeStepPair.first.toString(dateFormatString), timeStepPair.first));
|
||||
}
|
||||
addTimeStepsToMap(m_timeStepsToAddresses, displayTimeStepsMap);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user