|
|
|
@ -82,12 +82,8 @@ export class RecipeAddComponent {
|
|
|
|
|
}
|
|
|
|
|
const id = parseInt(value.selectedIngredient!);
|
|
|
|
|
if (this.ingredientEntries.find((ingredient) => ingredient.idIngredient === id)) {
|
|
|
|
|
console.log("oh");
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
console.log("ah");
|
|
|
|
|
console.log(this.ingredients.find(v => v.id === id)?.name)
|
|
|
|
|
console.log(this.ingredients);
|
|
|
|
|
this.ingredientEntries.push({
|
|
|
|
|
idIngredient: id,
|
|
|
|
|
idRecipe: -1,
|
|
|
|
|