public async Task Delete(int id) { var shop = await _context.FlowerShop.FindAsync(id); if (shop == null) { throw new NotFoundException(); } _context.FlowerShop.Remove(shop); await _context.SaveChangesAsync(); }
public async Task Delete(int id) { var bouquet = await _context.FlowerBouquet.FindAsync(id); if (bouquet == null) { throw new NotFoundException(); } _context.FlowerBouquet.Remove(bouquet); await _context.SaveChangesAsync(); }