Exemple #1
0
        public IActionResult Delete(VendedorModel ven)
        {
            VendedorDAO obj = new VendedorDAO();

            obj.Excluir(ven.Idvendedor);

            return(RedirectToAction(nameof(Index)));
        }
Exemple #2
0
 public void Excluir()
 {
     try
     {
         aTbVendedorDAO.Excluir(this);
     }
     catch (Exception ex)
     {
         throw new Exception("excluir o registro");
     }
     finally
     {
         Conexao.CloseConnection();
     }
 }