-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Recipe functionality #23
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Preliminary review. Mostly cosmetic since functionality isn't complete.
Initial apple having [1...6] for locationId and recipeId may not be intentional (bug?)
Initial recipes have item ids of items that don't exist.
src/main/java/seedu/address/logic/parser/AddRecipeCommandParser.java
Outdated
Show resolved
Hide resolved
src/main/java/seedu/address/logic/parser/AddRecipeCommandParser.java
Outdated
Show resolved
Hide resolved
@@ -18,4 +18,10 @@ | |||
public static final Prefix PREFIX_ITEM_DESCRIPTION = new Prefix("-d "); | |||
public static final Prefix PREFIX_ITEM_LOCATION = new Prefix("-l "); | |||
|
|||
// recipes start here | |||
public static final Prefix PREFIX_RECIPE_PRODUCT_NAME = new Prefix("-n "); | |||
public static final Prefix PREFIX_RECIPE_INGREDIENTS = new Prefix("-items "); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can consider shorter prefix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was specified in user guide, can be changed easily regardless
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just one bug, also need to remove test cases or update, LGTM
* Represents a Recipe's product's quantity number in the inventory. | ||
* Guarantees: immutable; is valid as declared in {@link #isValidQuantity(String)} | ||
*/ | ||
public class ProductQuantity { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can extend Quantity class if you want
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good note, modified
Refactor code base to be more general, add functionality to add recipes.
TODO: