Exemplo n.º 1
0
        public ActionResult Delete(int id)
        {
            var Cliente = Context.Clientes.Find(id);

            if (Cliente != null)
            {
                Context.Remove(Cliente);
                Context.SaveChanges();
                return(Ok());
            }
            else
            {
                return(NotFound());
            }
        }
Exemplo n.º 2
0
        public ActionResult Delete(int id)
        {
            var categoria = Context.Categoria.Find(id);

            if (categoria != null)
            {
                Context.Remove(categoria);
                Context.SaveChanges();
                return(Ok());
            }
            else
            {
                return(NotFound());
            }
        }
Exemplo n.º 3
0
 public Task Delete(User user)
 {
     _context.Remove(user);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 4
0
 public Task Delete(Genre genre)
 {
     _context.Remove(genre);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 5
0
 public Task Delete(ShoppingCart shoppingCart)
 {
     _context.Remove(shoppingCart);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 6
0
 public Task Delete(Review review)
 {
     _context.Remove(review);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 7
0
 public Task Delete(GameShoppingCartRel gameShoppingCartRel)
 {
     _context.Remove(gameShoppingCartRel);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 8
0
 public Task Delete(Platform platform)
 {
     _context.Remove(platform);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 9
0
 public Task Delete(Publisher publisher)
 {
     _context.Remove(publisher);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 10
0
 public Task Delete(Developer developer)
 {
     _context.Remove(developer);
     return(_context.SaveChangesAsync());
 }
Exemplo n.º 11
0
 public Task Delete(Game game)
 {
     _context.Remove(game);
     return(_context.SaveChangesAsync());
 }