#2127 Sim Well Branches : Move logic related to uiOrdering to RiaSimWellBranchTools

This commit is contained in:
Magne Sjaastad
2017-12-08 09:27:37 +01:00
parent f8e7a8aa26
commit 9c4077a040
3 changed files with 40 additions and 11 deletions

View File

@@ -759,15 +759,10 @@ void RimWellRftPlot::defineUiOrdering(QString uiConfigName, caf::PdmUiOrdering&
uiOrdering.add(&m_userName);
uiOrdering.add(&m_wellPathNameOrSimWellName);
if (!RimWellPlotTools::hasAssociatedWellPath(m_wellPathNameOrSimWellName))
{
uiOrdering.add(&m_branchDetection);
if (RiaSimWellBranchTools::simulationWellBranches(associatedSimWellName(), m_branchDetection).size() > 1)
{
uiOrdering.add(&m_branchIndex);
}
}
RiaSimWellBranchTools::appendSimWellBranchFieldsIfRequired(&uiOrdering,
m_wellPathNameOrSimWellName,
m_branchDetection,
m_branchIndex);
caf::PdmUiGroup* sourcesGroup = uiOrdering.addNewGroupWithKeyword("Sources", "Sources");
sourcesGroup->add(&m_selectedSources);