Beispiel #1
0
        public void CommandNew(object param)
        {
            var schoolYearSubject = (DataRow)SchoolYearViewModels.Current.SubjectViewModels.Current.Model;


            var dataRowMarkViewModel = MeineNoten.Class.MeineNoten.Database.Tables["Grades"].NewRow();

            dataRowMarkViewModel["SSID"] = schoolYearSubject["SSID"];

            var markViewModel = new MarkViewModel(dataRowMarkViewModel);

            Window newGradeWindow = new NewGradeWindow(SchoolYearViewModels.Current, markViewModel);

            newGradeWindow.ShowDialog();
        }
Beispiel #2
0
 public NewGradeWindowViewModel(SchoolYearViewModel schoolYearViewModel, MarkViewModel markViewModel)
 {
     this.SchoolYearViewModel = schoolYearViewModel;
     this.MarkViewModel       = markViewModel;
     this.SaveCommand         = new RelayCommand(CommandSave, CanExecuteSave);
 }