コード例 #1
0
ファイル: ParcticalView.xaml.cs プロジェクト: Ireki/vkr
 private void deleteRowVKR(object sender, RoutedEventArgs e)
 {
     Model.Practical itemFocus = practicalGrid.SelectedValue as Model.Practical;
     itemFocus.DateDeleted = DateTime.Now;
     db.SaveChanges();
     LoadPractical();
     FindCount();
 }
コード例 #2
0
ファイル: ParcticalView.xaml.cs プロジェクト: Ireki/vkr
        private void changeRowVKR(object sender, RoutedEventArgs e)
        {
            Model.Practical      itemFocus       = practicalGrid.SelectedValue as Model.Practical;
            AddOrChangePractical changePractical = new AddOrChangePractical(itemFocus, db);

            changePractical.ShowDialog();
            LoadPractical();
            FindCount();
        }
コード例 #3
0
ファイル: AddOrChanePractical.xaml.cs プロジェクト: Ireki/vkr
 public AddOrChangePractical(Model.Practical practical, DocumentsContext db)
 {
     InitializeComponent();
     this.practical                = practical;
     this.db                       = db;
     btnModify.Content             = "Изменить";
     textBlockGroup.Text           = practical.Group;
     textBlockName.Text            = practical.Name;
     textBlockSurname.Text         = practical.Surname;
     textBlockPatronymic.Text      = practical.Patronymic;
     textBlockPracticeBase.Text    = practical.PracticeBase;
     textBlockHumanSettlement.Text = practical.HumanSettlement;
     textBlockStartOfPractice.Text = practical.StartOfPractice.ToString();
     textBlockEndOfPractice.Text   = practical.EndOfPractice.ToString();
     textBlockFormOfPractice.Text  = practical.FormOfPractice;
     textBlockFormOfPractice.Text  = practical.Payment;
     textBlockDirector.Text        = practical.Director;
 }
コード例 #4
0
ファイル: AddOrChanePractical.xaml.cs プロジェクト: Ireki/vkr
 public AddOrChangePractical(DocumentsContext db)
 {
     InitializeComponent();
     this.db   = db;
     practical = new Model.Practical();
 }