public ChoseStudy(bool forCompare) { _context = MainContext.GetInstance(); Studies = new ObservableCollection<Study>(_context.Studies.ToList()); DeleteButtonClickCommand = new Command(arg => DeleteButtonClickMethod(arg as Window)); if (forCompare) ShowStudyClickCommand = new Command(args => CompareStudyClickMethod(args)); else ShowStudyClickCommand = new Command(args => ShowStudyClickMethod(args)); }
public static StudyContext GetInstance() { if (_context == null) _context = new StudyContext(); return _context; }