#1382 Removed the FlowDiagnostics solutions from the Gui. Always using the one and only default solution

This commit is contained in:
Jacob Støren 2017-04-06 10:59:52 +02:00
parent 970595e0f5
commit 3e37eec71c
4 changed files with 18 additions and 6 deletions

View File

@ -52,6 +52,8 @@ RimFlowCharacteristicsPlot::RimFlowCharacteristicsPlot()
CAF_PDM_InitFieldNoDefault(&m_case, "FlowCase", "Case", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_case, "FlowCase", "Case", "", "", "");
CAF_PDM_InitFieldNoDefault(&m_flowDiagSolution, "FlowDiagSolution", "Flow Diag Solution", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_flowDiagSolution, "FlowDiagSolution", "Flow Diag Solution", "", "", "");
m_flowDiagSolution.uiCapability()->setUiHidden(true);
CAF_PDM_InitFieldNoDefault(&m_timeStepSelectionType, "TimeSelectionType", "Time Steps", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_timeStepSelectionType, "TimeSelectionType", "Time Steps", "", "", "");
CAF_PDM_InitFieldNoDefault(&m_selectedTimeSteps, "SelectedTimeSteps", "", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_selectedTimeSteps, "SelectedTimeSteps", "", "", "", "");

View File

@ -82,7 +82,7 @@ RimWellAllocationPlot::RimWellAllocationPlot()
CAF_PDM_InitField(&m_timeStep, "PlotTimeStep", 0, "Time Step", "", "", ""); CAF_PDM_InitField(&m_timeStep, "PlotTimeStep", 0, "Time Step", "", "", "");
CAF_PDM_InitField(&m_wellName, "WellName", QString("None"), "Well", "", "", ""); CAF_PDM_InitField(&m_wellName, "WellName", QString("None"), "Well", "", "", "");
CAF_PDM_InitFieldNoDefault(&m_flowDiagSolution, "FlowDiagSolution", "Flow Diag Solution", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_flowDiagSolution, "FlowDiagSolution", "Plot Type", "", "", "");
CAF_PDM_InitFieldNoDefault(&m_flowType, "FlowType", "Flow Type", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_flowType, "FlowType", "Flow Type", "", "", "");
CAF_PDM_InitField(&m_groupSmallContributions, "GroupSmallContributions", true, "Group Small Contributions", "", "", ""); CAF_PDM_InitField(&m_groupSmallContributions, "GroupSmallContributions", true, "Group Small Contributions", "", "", "");
CAF_PDM_InitField(&m_smallContributionsThreshold, "SmallContributionsThreshold", 0.005, "Threshold", "", "", ""); CAF_PDM_InitField(&m_smallContributionsThreshold, "SmallContributionsThreshold", 0.005, "Threshold", "", "", "");
@ -593,12 +593,18 @@ QList<caf::PdmOptionItemInfo> RimWellAllocationPlot::calculateValueOptions(const
{ {
if (m_case) if (m_case)
{ {
std::vector<RimFlowDiagSolution*> flowSols = m_case->flowDiagSolutions(); //std::vector<RimFlowDiagSolution*> flowSols = m_case->flowDiagSolutions();
//for (RimFlowDiagSolution* flowSol : flowSols)
//{
// options.push_back(caf::PdmOptionItemInfo("None", nullptr));
// options.push_back(caf::PdmOptionItemInfo(flowSol->userDescription(), flowSol, false, flowSol->uiIcon()));
//}
for (RimFlowDiagSolution* flowSol : flowSols) RimFlowDiagSolution* defaultFlowSolution = m_case->defaultFlowDiagSolution();
options.push_back(caf::PdmOptionItemInfo("Well Flow", nullptr));
if (defaultFlowSolution)
{ {
options.push_back(caf::PdmOptionItemInfo("None", nullptr)); options.push_back(caf::PdmOptionItemInfo("Allocation", defaultFlowSolution ));
options.push_back(caf::PdmOptionItemInfo(flowSol->userDescription(), flowSol, false, flowSol->uiIcon()));
} }
} }
} }

View File

@ -59,6 +59,9 @@ RimEclipseResultCase::RimEclipseResultCase()
caseFileName.uiCapability()->setUiReadOnly(true); caseFileName.uiCapability()->setUiReadOnly(true);
CAF_PDM_InitFieldNoDefault (&m_flowDiagSolutions, "FlowDiagSolutions", "Flow Diagnostics Solutions", "", "", ""); CAF_PDM_InitFieldNoDefault (&m_flowDiagSolutions, "FlowDiagSolutions", "Flow Diagnostics Solutions", "", "", "");
m_flowDiagSolutions.uiCapability()->setUiHidden(true);
m_flowDiagSolutions.uiCapability()->setUiTreeHidden(true);
m_flowDiagSolutions.uiCapability()->setUiTreeChildrenHidden(true);
// Obsolete, unused field // Obsolete, unused field
CAF_PDM_InitField(&caseDirectory, "CaseFolder", QString(), "Directory", "", "" ,""); CAF_PDM_InitField(&caseDirectory, "CaseFolder", QString(), "Directory", "", "" ,"");

View File

@ -100,6 +100,7 @@ RimEclipseResultDefinition::RimEclipseResultDefinition()
CAF_PDM_InitFieldNoDefault(&m_flowSolutionUiField, "MFlowDiagSolution", "Solution", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_flowSolutionUiField, "MFlowDiagSolution", "Solution", "", "", "");
m_flowSolutionUiField.xmlCapability()->setIOReadable(false); m_flowSolutionUiField.xmlCapability()->setIOReadable(false);
m_flowSolutionUiField.xmlCapability()->setIOWritable(false); m_flowSolutionUiField.xmlCapability()->setIOWritable(false);
m_flowSolutionUiField.uiCapability()->setUiHidden(true); // For now since there are only one to choose from
CAF_PDM_InitFieldNoDefault(&m_selectedTracersUiField, "MSelectedTracers", " ", "", "", ""); CAF_PDM_InitFieldNoDefault(&m_selectedTracersUiField, "MSelectedTracers", " ", "", "", "");
m_selectedTracersUiField.xmlCapability()->setIOReadable(false); m_selectedTracersUiField.xmlCapability()->setIOReadable(false);