diff options
Diffstat (limited to 'recipeBuddy/src/app/add-recipe/add-recipe.component.ts')
-rw-r--r-- | recipeBuddy/src/app/add-recipe/add-recipe.component.ts | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/recipeBuddy/src/app/add-recipe/add-recipe.component.ts b/recipeBuddy/src/app/add-recipe/add-recipe.component.ts index 469871b..cdd63c8 100644 --- a/recipeBuddy/src/app/add-recipe/add-recipe.component.ts +++ b/recipeBuddy/src/app/add-recipe/add-recipe.component.ts @@ -61,6 +61,10 @@ export class AddRecipeComponent { ); } + rmIngredient(i) { + this.ingredients.removeAt(i); + } + get steps() { return this.recipeForm.get('steps') as FormArray; } @@ -74,6 +78,10 @@ export class AddRecipeComponent { ); } + rmStep(i) { + this.steps.removeAt(i); + } + onSubmit() { var formData = this.recipeForm.value; |