/// <summary> /// Sets up the dropdown combobox for the phases. /// </summary> /// <param name="stages"></param> private void SetUpCombobox(StageDTO[] stages) { if (stages != null) { phaseComboBox.Items.Clear(); foreach (var s in stages) { phaseComboBox.Items.Add(s); } phaseComboBox.DisplayMemberPath = "Name"; } }
/// <summary> /// Sets up the page from the logic object. /// </summary> /// <param name="study"></param> private void SetUpFromStudy(StudyDTO study) { _stageToWorkOn = new StageDTO(); _stageToWorkOn.StudyID = _logic._StudyToWorkOn.Id; _users = new List<UserDTO>(); _validators = new List<UserDTO>(); _reviewers = new List<UserDTO>(); _users.AddRange(_logic._Users); SetUpBoxes(); }
/// <summary> /// Remove a selected phase from the logic. /// </summary> /// <param name="stageToRemove"></param> public void RemoveStage(StageDTO stageToRemove) { var stages = _StudyToWorkOn.Stages; _StudyToWorkOn.Stages = stages.Where(val => val != stageToRemove).ToArray(); }