forked from nus-cs2103-AY2324S2/tp
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
24 changed files
with
105 additions
and
463 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,6 +68,8 @@ Examples: | |
* `add_applicant n/John Doe p/81239123 e/[email protected]` | ||
* `add_applicant n/John Doe p/81239123 e/[email protected] t/friends t/cool` | ||
|
||
Note that the remark field would be empty be default and can only be changed after the person is added. | ||
|
||
## Adding a status to an applicant: `applicant_status` | ||
|
||
Now that you know how to add an applicant, it would be nice to record their position in your hiring pipeline at any given time for later review. This is where the applicant_status command is handy. | ||
|
@@ -102,6 +104,8 @@ Examples: | |
* `add_interviewer n/John Doe p/81239123 e/[email protected]` | ||
* `add_interviewer n/John Doe p/81239123 e/[email protected] t/friends t/cool` | ||
|
||
Note that the remark field would be empty be default and can only be changed after the person is added. | ||
|
||
|
||
## Adding a status to an interviewer: `interviewer_status` | ||
|
||
|
@@ -122,7 +126,18 @@ A simple example usage for when manually tweaking an interviewer's status is nec | |
* Tether is capable of appending an interviewer's status _automatically_ with "interview with APPLICANT NAME" when an interview concerning the respective interviewer is added. Conversely if the interview is deleted, the **particular** applicant's "interview with..." is deleted. For example if interviewer Nicole's current status is "interview with Yash interview with Ryan", if you delete an interview with Yash, Nicole's status will become "interview with ryan" | ||
* We give you the freedom to append any number of statuses to an existing interviewer i.e. we **do not** currently check against adding duplicate statuses | ||
|
||
## Adding a interview: `add_interview` | ||
## Adding a remark to an applicant/interviewer: `remark` | ||
|
||
Once you have applicants/interviewers in Tether, you might want to add some remarks to each individual. This is where the `remark` | ||
command would come in handy. Simply execute `remark INDEX r/REMARK`. | ||
|
||
For example, executing `remark 1 r/Confident` would add the | ||
"Confident" remark to the person at index 1. | ||
|
||
Note that if you only execute `remark INDEX`, the remark of the person at that index would be removed. | ||
|
||
|
||
## Adding an interview: `add_interview` | ||
|
||
Now that you have applicants and interviewers inside tether, you can create an interview. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
package seedu.address.logic.commands; | ||
|
||
import static java.util.Objects.requireNonNull; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_EMAIL; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_NAME; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_PHONE; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_TAG; | ||
|
||
import seedu.address.commons.util.ToStringBuilder; | ||
import seedu.address.logic.Messages; | ||
|
@@ -16,12 +20,17 @@ public class AddApplicantPersonCommand extends AddPersonCommand { | |
public static final String COMMAND_WORD = AddPersonCommand.COMMAND_WORD + "_applicant"; | ||
|
||
public static final String MESSAGE_USAGE = COMMAND_WORD + ": Adds an applicant to Tether. " | ||
+ AddPersonCommand.MESSAGE_USAGE; | ||
+ AddPersonCommand.MESSAGE_USAGE | ||
+ "Example: " + COMMAND_WORD + " " | ||
+ PREFIX_NAME + "John Doe " | ||
+ PREFIX_PHONE + "98765432 " | ||
+ PREFIX_EMAIL + "[email protected] " | ||
+ PREFIX_TAG + "friends "; | ||
|
||
|
||
public static final String MESSAGE_SUCCESS = "New applicant added: %1$s"; | ||
public static final String MESSAGE_DUPLICATE_PERSON = "This applicant already exists in Tether." | ||
+ " Do ensure phone number is unique"; | ||
public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in Tether." | ||
+ " Do ensure phone number and email are unique!"; | ||
|
||
|
||
/** | ||
|
@@ -35,7 +44,7 @@ public AddApplicantPersonCommand(Person person) { | |
public CommandResult execute(Model model) throws CommandException { | ||
requireNonNull(model); | ||
|
||
if (model.hasPerson(toAdd) || model.hasPersonWithSamePhone(toAdd)) { | ||
if (model.hasPerson(toAdd) || model.hasPersonWithSamePhone(toAdd) || model.hasPersonWithSameEmail(toAdd)) { | ||
throw new CommandException(MESSAGE_DUPLICATE_PERSON); | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
package seedu.address.logic.commands; | ||
|
||
import static java.util.Objects.requireNonNull; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_EMAIL; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_NAME; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_PHONE; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_TAG; | ||
|
||
import seedu.address.commons.util.ToStringBuilder; | ||
import seedu.address.logic.Messages; | ||
|
@@ -16,11 +20,16 @@ public class AddInterviewerPersonCommand extends AddPersonCommand { | |
public static final String COMMAND_WORD = AddPersonCommand.COMMAND_WORD + "_interviewer"; | ||
|
||
public static final String MESSAGE_USAGE = COMMAND_WORD + ": Adds an interviewer to Tether. " | ||
+ AddPersonCommand.MESSAGE_USAGE; | ||
+ AddPersonCommand.MESSAGE_USAGE | ||
+ "Example: " + COMMAND_WORD + " " | ||
+ PREFIX_NAME + "John Doe " | ||
+ PREFIX_PHONE + "98765432 " | ||
+ PREFIX_EMAIL + "[email protected] " | ||
+ PREFIX_TAG + "friends "; | ||
|
||
public static final String MESSAGE_SUCCESS = "New interviewer added: %1$s"; | ||
public static final String MESSAGE_DUPLICATE_PERSON = "This interviewer already exists in the Tether." | ||
+ " Do ensure phone number is unique"; | ||
public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in the Tether." | ||
+ " Do ensure phone number and email are unique!"; | ||
|
||
/** | ||
* Creates an AddInterviewerCommand to add the specified {@code Person} | ||
|
@@ -33,7 +42,7 @@ public AddInterviewerPersonCommand(Person person) { | |
public CommandResult execute(Model model) throws CommandException { | ||
requireNonNull(model); | ||
|
||
if (model.hasPerson(toAdd) || model.hasPersonWithSamePhone(toAdd)) { | ||
if (model.hasPerson(toAdd) || model.hasPersonWithSamePhone(toAdd) || model.hasPersonWithSameEmail(toAdd)) { | ||
throw new CommandException(MESSAGE_DUPLICATE_PERSON); | ||
} | ||
|
||
|
149 changes: 0 additions & 149 deletions
149
src/main/java/seedu/address/logic/commands/AddInterviewerStatusCommand.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,6 @@ | |
import static seedu.address.logic.parser.CliSyntax.PREFIX_EMAIL; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_NAME; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_PHONE; | ||
import static seedu.address.logic.parser.CliSyntax.PREFIX_TAG; | ||
|
||
import seedu.address.model.person.Person; | ||
|
||
|
@@ -18,14 +17,7 @@ public abstract class AddPersonCommand extends Command { | |
public static final String MESSAGE_USAGE = "Parameters: " | ||
+ PREFIX_NAME + "NAME " | ||
+ PREFIX_PHONE + "PHONE " | ||
+ PREFIX_EMAIL + "EMAIL " | ||
+ "[" + PREFIX_TAG + "TAG]...\n" | ||
+ "Example: " + COMMAND_WORD + " " | ||
+ PREFIX_NAME + "John Doe " | ||
+ PREFIX_PHONE + "98765432 " | ||
+ PREFIX_EMAIL + "[email protected] " | ||
+ PREFIX_TAG + "friends " | ||
+ PREFIX_TAG + "owesMoney"; | ||
+ PREFIX_EMAIL + "EMAIL "; | ||
|
||
public static final String MESSAGE_SUCCESS = "New person added: %1$s"; | ||
public static final String MESSAGE_DUPLICATE_PERSON = "This person already exists in the address book"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 0 additions & 39 deletions
39
src/main/java/seedu/address/logic/parser/AddInterviewerStatusCommandParser.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.