-
Notifications
You must be signed in to change notification settings - Fork 0
Use Case 7: Add Ingredient
Mason Daugherty edited this page Jul 30, 2024
·
1 revision
User selected the Add Ingredient
option from the menu [UC1].
- A user selects the option to add an Ingredient.
- The user enters the name of the new Ingredient (only one ingredient may be added at a time).
- The system validates the Ingredient name. [Validate Name]
- The user confirms the name of the Ingredient.
- The new Ingredient is added to the database. [Validate Addition]
- A message indicating that the Ingredient is added will be displayed.
- The user may return to the main menu [UC1] or add another Ingredient.
- [Validate Name] Validate the string entry [Letter Only] [Character Count].
- [Validate Addition] Checks whether the Ingredient is valid before adding [Duplicate] [Ingredient Cap]. Assumes that [Validate Name] passed.
- [Duplicate] If the name of the new Ingredient already exists in the system, an error message is displayed, and the user is returned to the form to edit. The Ingredient is not added.
- [Letter Only] If the name of the new Ingredient contains non-letter characters, an error message is displayed, and the user is returned to the form to edit. The Ingredient is not added.
- [Ingredient Cap] Only 50 Ingredients can exist in the database. If adding this Ingredient causes this count to exceed the cap, an error message is displayed and the user is returned to the form. The Ingredient is not added.
- [Character Count] Only 15 characters are allowed in an Ingredient name. If the name passed in is greater than 15, an error message is displayed, and the user is returned to the form to edit. The Ingredient is not added.