Ejemplo n.º 1
0
        public JsonResult ReadIngredientById(int ingredientID)
        {
            if (ingredientID <= 0)
            {
                return(Json(new { errors = "Ingredient ID is <= 0" }));
            }

            return(Json(_dbService.ReadElementById(ingredientID)));
        }
Ejemplo n.º 2
0
        public JsonResult ReadRecipeById(int recipeID)
        {
            if (recipeID <= 0)
            {
                return(Json(new { errors = "Recipe ID is <= 0" }));
            }

            return(Json(_dbService.ReadElementById(recipeID)));
        }