public void openDeleteCustomerView(contact customer) { DeleteCustomerViewModel deleteCustomerViewModel = new DeleteCustomerViewModel(customer); DeleteCustomerView deleteCustomerView = new DeleteCustomerView(); deleteCustomerView.DataContext = deleteCustomerViewModel; deleteCustomerViewModel.CloseActionDelete = new Action(() => deleteCustomerView.Close()); deleteCustomerView.ShowDialog(); }
private void deleteCallback(DeleteCustomerView view, contact customer) { view.Close(); customers.Remove(customer); NotifyPropertyChanged("customers"); }