Skip to content

Commit

Permalink
Fixes #2322 pk parameters tab empty (#2332)
Browse files Browse the repository at this point in the history
  • Loading branch information
msevestre authored Sep 12, 2022
1 parent 2ee6143 commit d309aa9
Show file tree
Hide file tree
Showing 8 changed files with 164 additions and 190 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,15 @@ public class CreateTimeProfileAnalysisPresenter : CreatePopulationAnalysisPresen
{
private readonly ILazyLoadTask _lazyLoadTask;

public CreateTimeProfileAnalysisPresenter(ICreatePopulationAnalysisView view, ISubPresenterItemManager<IPopulationAnalysisItemPresenter> subPresenterItemManager,
IDialogCreator dialogCreator, IPopulationAnalysisTemplateTask populationAnalysisTemplateTask, IPopulationAnalysisChartFactory populationAnalysisChartFactory, ILazyLoadTask lazyLoadTask, IPopulationAnalysisTask populationAnalysisTask, IPopulationAnalysisFieldFactory populationAnalysisFieldFactory)
public CreateTimeProfileAnalysisPresenter(
ICreatePopulationAnalysisView view,
ISubPresenterItemManager<IPopulationAnalysisItemPresenter> subPresenterItemManager,
IDialogCreator dialogCreator,
IPopulationAnalysisTemplateTask populationAnalysisTemplateTask,
IPopulationAnalysisChartFactory populationAnalysisChartFactory,
ILazyLoadTask lazyLoadTask,
IPopulationAnalysisTask populationAnalysisTask,
IPopulationAnalysisFieldFactory populationAnalysisFieldFactory)
: base(view, subPresenterItemManager, TimeProfileItems.All, dialogCreator, populationAnalysisTemplateTask, populationAnalysisChartFactory, populationAnalysisTask, populationAnalysisFieldFactory)
{
_lazyLoadTask = lazyLoadTask;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
using OSPSuite.Utility.Events;
using OSPSuite.Core.Domain;
using OSPSuite.Utility.Events;
using OSPSuite.Utility.Extensions;
using PKSim.Core.Events;
using PKSim.Core.Model;
using PKSim.Core.Model.PopulationAnalyses;
using PKSim.Presentation.Presenters.Populations;
using PKSim.Presentation.Views.PopulationAnalyses;
using OSPSuite.Core.Domain;

namespace PKSim.Presentation.Presenters.PopulationAnalyses
{
Expand All @@ -24,8 +24,10 @@ public class PopulationAnalysisPKParameterSelectionPresenter : PopulationAnalysi
private readonly IPopulationAnalysisAvailablePKParametersPresenter _allPKParametersPresenter;
private readonly IPopulationAnalysisPKParameterFieldsPresenter _selectedPKParameterFieldsPresenter;

public PopulationAnalysisPKParameterSelectionPresenter(IPopulationAnalysisPKParameterSelectionView view,
IPopulationAnalysisAvailablePKParametersPresenter allPKParametersPresenter, IPopulationAnalysisPKParameterFieldsPresenter selectedPKParameterFieldsPresenter,
public PopulationAnalysisPKParameterSelectionPresenter(
IPopulationAnalysisPKParameterSelectionView view,
IPopulationAnalysisAvailablePKParametersPresenter allPKParametersPresenter,
IPopulationAnalysisPKParameterFieldsPresenter selectedPKParameterFieldsPresenter,
IPopulationAnalysisFieldDistributionPresenter populationAnalysisFieldDistributionPresenter)
: base(view, populationAnalysisFieldDistributionPresenter)
{
Expand All @@ -43,10 +45,7 @@ public PopulationAnalysisPKParameterSelectionPresenter(IPopulationAnalysisPKPara
AddSubPresenters(_allPKParametersPresenter, _selectedPKParameterFieldsPresenter);
}

private void drawDistributionFor(PKParameterFieldSelectedEventArgs e)
{
drawDistributionFor(e.PKParameter, e.PKParameterField);
}
private void drawDistributionFor(PKParameterFieldSelectedEventArgs e) => drawDistributionFor(e.PKParameter, e.PKParameterField);

private void drawDistributionFor(QuantityPKParameter pkParameter, PopulationAnalysisPKParameterField populationAnalysisPKParameterField)
{
Expand Down Expand Up @@ -78,8 +77,8 @@ public void RemovePKParameters()

public bool ScalingVisible
{
set { _selectedPKParameterFieldsPresenter.ScalingVisible = value; }
get { return _selectedPKParameterFieldsPresenter.ScalingVisible; }
set => _selectedPKParameterFieldsPresenter.ScalingVisible = value;
get => _selectedPKParameterFieldsPresenter.ScalingVisible;
}

protected override void RedrawDistribution(PopulationAnalysisFieldEvent eventToHandle)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,12 @@ public class PopulationAnalysisParameterSelectionPresenter : PopulationAnalysisS
private readonly IPopulationAnalysisParameterFieldsPresenter _selectedPopulationParametersPresenter;
private readonly IEntityPathResolver _entityPathResolver;

public PopulationAnalysisParameterSelectionPresenter(IPopulationAnalysisParameterSelectionView view, IPopulationParameterGroupsPresenter allPopulationParametersPresenter, IPopulationAnalysisParameterFieldsPresenter selectedPopulationParametersPresenter, IEntityPathResolver entityPathResolver, IPopulationAnalysisFieldDistributionPresenter populationAnalysisFieldDistributionPresenter)
public PopulationAnalysisParameterSelectionPresenter(
IPopulationAnalysisParameterSelectionView view,
IPopulationParameterGroupsPresenter allPopulationParametersPresenter,
IPopulationAnalysisParameterFieldsPresenter selectedPopulationParametersPresenter,
IEntityPathResolver entityPathResolver,
IPopulationAnalysisFieldDistributionPresenter populationAnalysisFieldDistributionPresenter)
: base(view, populationAnalysisFieldDistributionPresenter)
{
_allPopulationParametersPresenter = allPopulationParametersPresenter;
Expand Down
Loading

0 comments on commit d309aa9

Please sign in to comment.