public void CleanUp() { CocktailLiquid.Delete(); CocktailLiquid.Save(); Cocktail.Delete(); Cocktail.Save(); Liquid.Delete(); Liquid.Save(); }
public void InsertCocktail(Model.Cocktail newCocktail) { Cocktail.Create(new Cocktail { Name = newCocktail.Name }); Cocktail.Save(); foreach (var ingredient in newCocktail.Ingredients) { repositoryContext.AddIngredient(newCocktail.Name, ingredient.Name, ingredient.Quantity); } }