private void cancellButton_Click(object sender, EventArgs e)//取消预约,完成 { Book book = appointBindingSource.Current as Book; if (book == null) { MessageBox.Show("请选择一本书进行操作!"); return; } BookShelfService.CancellAppoint(book, currentClient); appointBooks = new List <Book>(); appointBindingSource.DataSource = appointBooks; appointBooks = BookShelfService.GetAllAppointedBooks(currentClient); appointBindingSource.ResetBindings(false); appointBindingSource.DataSource = appointBooks; Books = new List <Book>(); booksBindingSource.DataSource = Books; Books = BookShelfService.AllBooks(); booksBindingSource.ResetBindings(false); booksBindingSource.DataSource = Books; Query(1); }