private async Task RefreshLendDataGride() { var lendedBookViewSource = (CollectionViewSource)FindResource("lendedBookViewSource"); lendedBookViewSource.Source = await LendedBookOperations.LendedBooksToListAsync(selectedStudent); }
private void BTNReturnBook_Click(object sender, RoutedEventArgs e) { if (selectedStudent != null && selectedLendedBook != null) { LendedBookOperations.ReturnBook(selectedStudent, selectedLendedBook); } }
private void BTNAddBookToStudent_Click(object sender, RoutedEventArgs e) { if (DPDateOfReturn.SelectedDate != null && selectedStudent != null && selectedBook != null) { LendedBookOperations.LendBook(selectedStudent, selectedBook, DPDateOfReturn.SelectedDate.Value); } }