#6138 Valve Export : Make sure the valves always use the valve interval, not perforation interval

This commit is contained in:
Magne Sjaastad 2020-06-24 11:58:59 +02:00
parent 52fc12adf3
commit 44b3cb76df

View File

@ -268,8 +268,9 @@ std::vector<std::pair<double, double>> RimWellPathValve::valveSegments() const
RimPerforationInterval* perforationInterval = nullptr;
this->firstAncestorOrThisOfType( perforationInterval );
double startMD = perforationInterval->startMD();
double endMD = perforationInterval->endMD();
double startMD = this->startMD();
double endMD = this->endMD();
std::vector<double> valveMDs = valveLocations();
std::vector<std::pair<double, double>> segments;
@ -385,7 +386,7 @@ double RimWellPathValve::startMD() const
{
return m_measuredDepth;
}
else if ( m_multipleValveLocations()->valveLocations().empty() )
else if ( m_multipleValveLocations()->valveLocations().size() < 2 )
{
return m_multipleValveLocations->rangeStart();
}
@ -404,7 +405,7 @@ double RimWellPathValve::endMD() const
{
return m_measuredDepth + 0.5;
}
else if ( m_multipleValveLocations()->valveLocations().empty() )
else if ( m_multipleValveLocations()->valveLocations().size() < 2 )
{
return m_multipleValveLocations->rangeEnd();
}