Skip to content
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

create customer class #61

Merged
merged 12 commits into from Sep 27, 2019
Merged

Conversation

EugeneTeu
Copy link

No description provided.

Copy link

@yan-wl yan-wl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to update javadocs and comments.

LICENSE Outdated Show resolved Hide resolved
LICENSE Outdated Show resolved Hide resolved
docs/DeveloperGuide.adoc Outdated Show resolved Hide resolved
docs/UserGuide.adoc Outdated Show resolved Hide resolved
docs/UserGuide.adoc Outdated Show resolved Hide resolved
src/main/java/seedu/address/model/person/Phone.java Outdated Show resolved Hide resolved
src/main/java/seedu/address/storage/JsonAdaptedPerson.java Outdated Show resolved Hide resolved
src/main/java/seedu/address/ui/PersonCard.java Outdated Show resolved Hide resolved
src/main/java/seedu/address/ui/PersonListPanel.java Outdated Show resolved Hide resolved
@EugeneTeu EugeneTeu requested review from yan-wl, yeodonghan and a team and removed request for a team September 27, 2019 06:59


public static final String MESSAGE_CONSTRAINTS =
"ContactNumber numbers should only contain numbers, and it should be at least 3 digits long";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

contact number should be 8 numbers instead i think

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed


/**
* Returns true if both customers have the same identity and data fields.
* This defines a stronger notion of equality between two persons.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

javadoc comment change to customers

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Copy link

@yan-wl yan-wl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some minor changes needed


public static final String MESSAGE_CONSTRAINTS =
"ContactNumber numbers should only contain numbers, and it should be at least 8 digits long";
public static final String VALIDATION_REGEX = "\\d{3,}";
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be \d{8,}

import seedu.address.commons.util.StringUtil;

/**
* Tests that a {@code Person}'s {@code Name} matches any of the keywords given.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be Customer instead of Person

}

/**
* Adds a person to the list.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be customer instead of person

*/
public class CustomerCard extends UiPart<Region> {

private static final String FXML = "PersonListCard.fxml";
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps leave a TODO to remind to change when the fxml is ready

* Panel containing the list of persons.
*/
public class CustomerListPanel extends UiPart<Region> {
private static final String FXML = "PersonListPanel.fxml";
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps mark TODO

}

/**
* Custom {@code ListCell} that displays the graphics of a {@code Person} using a {@code PersonCard}.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be customer

/**
* Replaces the customer {@code target} in the list with {@code editedCustomer}.
* {@code target} must exist in the list.
* The person identity of {@code editedCustomer} must not be the same as another existing customer in the list.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should it be customer identity?


/**
* Removes the equivalent customer from the list.
* The person must exist in the list.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

person change to customer !

import seedu.address.model.customer.exceptions.DuplicateCustomerException;

/**
* A list of persons that enforces uniqueness between its elements and does not allow nulls.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all the persons should be changed to customer i think

@EugeneTeu EugeneTeu merged commit 3ebbcfe into AY1920S1-CS2103T-T09-4:master Sep 27, 2019
@EugeneTeu EugeneTeu added the priority.High Must do label Sep 28, 2019
@EugeneTeu EugeneTeu removed the priority.High Must do label Oct 4, 2019
@EugeneTeu EugeneTeu self-assigned this Oct 4, 2019
@EugeneTeu EugeneTeu added this to the v1.2 milestone Oct 9, 2019
@EugeneTeu EugeneTeu added the priority.High Must do label Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants