コード例 #1
0
        /// <summary>
        /// Executes the delete client command
        /// </summary>
        /// <param name="parameter">binding parameter</param>
        public void DeleteClient(object parameter)
        {
            // Warn user that the action can't be undone
            if (System.Windows.MessageBoxResult.OK == System.Windows.MessageBox.Show(Properties.Resources.DeleteMessage,
                                                                                     Properties.Resources.DeleteCaption,
                                                                                     System.Windows.MessageBoxButton.OKCancel,
                                                                                     System.Windows.MessageBoxImage.Warning))
            {
                // run the delete client function
                m_clientsBL.DeleteClient(SelectedClient);

                // clear the selected client as it has now been deleted
                SelectedClient = null;
                ClearValues();
            }
        }
コード例 #2
0
 public async Task <ActionResult <Clients> > Delete(int id)
 {
     return(await _IClientsBL.DeleteClient(id));
 }