diff --git a/.travis.yml b/.travis.yml index 4d6f37d8ba8b..4a41176953e0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,7 +5,7 @@ matrix: script: >- ./config/travis/run-checks.sh && - travis_retry ./gradlew clean checkstyleMain checkstyleTest headless allTests coverage coveralls asciidoctor copyDummySearchPage + travis_retry ./gradlew clean checkstyleMain checkstyleTest headless allTests coverage coveralls asciidoctor deploy: skip_cleanup: true diff --git a/build.gradle b/build.gradle index 50cd2ae52efc..894a6b8e0c4e 100644 --- a/build.gradle +++ b/build.gradle @@ -196,11 +196,6 @@ task deployOfflineDocs(type: Copy) { } } -task copyDummySearchPage(type: Copy) { - from 'docs/DummySearchPage.html' - into "${buildDir}/docs/html5" -} - deployOfflineDocs.dependsOn asciidoctor processResources.dependsOn deployOfflineDocs diff --git a/docs/DummySearchPage.html b/docs/DummySearchPage.html deleted file mode 100644 index 1607d4c57291..000000000000 --- a/docs/DummySearchPage.html +++ /dev/null @@ -1,32 +0,0 @@ - - - - - Dummy Search Page - - - - Hi : This is a placeholder page for se-edu/addressbook-level4.
- You may update the code to load a page from a real service (e.g., Google search).
- This dummy page is used here because, given the high number of forks of this repo, loading a page from a real third-party service by default can result in that service taking counter-measures (e.g., redirecting to captcha pages) due to the high number of rapid requests received from a single IP.
- When you have made the change, please remove: -
    -
  1. This file (docs/DummySearchPage.html).
  2. -
  3. Task copyDummySearchPage in both build.gradle and .travis.yml.
  4. -
- - diff --git a/docs/UserGuide.adoc b/docs/UserGuide.adoc index 00ce60f98302..58b2c0a06654 100644 --- a/docs/UserGuide.adoc +++ b/docs/UserGuide.adoc @@ -1,8 +1,4 @@ -<<<<<<< HEAD -= TuitionConnect - User Guide -======= = TuitionConnect (TC) - User Guide ->>>>>>> 58ffc0c220cddca68ac2bfcc9faa4a6478744261 :toc: :toc-title: :toc-placement: preamble @@ -21,11 +17,7 @@ By: `Team MarvelousBook` Since: `Feb 2018` Licence: `MIT` == Introduction -<<<<<<< HEAD -TuitionConnect (AB4) is for those who *prefer to use a desktop app for managing contacts*. More importantly, TC is *optimized for those who prefer to work with a Command Line Interface* (CLI) while still having the benefits of a Graphical User Interface (GUI). If you can type fast, TC can get your contact management tasks done faster than traditional GUI apps. Interested? Jump to the <> to get started. Enjoy! -======= TuitionConnect (TC) is for those who *prefer to use a desktop app for managing contacts*. More importantly, TC is *optimized for those who prefer to work with a Command Line Interface* (CLI) while still having the benefits of a Graphical User Interface (GUI). If you can type fast, TC can get your contact management tasks done faster than traditional GUI apps. Interested? Jump to the <> to get started. Enjoy! ->>>>>>> 58ffc0c220cddca68ac2bfcc9faa4a6478744261 == Quick Start @@ -288,16 +280,10 @@ Format: `exit` Address book data are saved in the hard disk automatically after any command that changes the data. + There is no need to save manually. -=== Complete task `[coming in v1.2]` -Marks a task as completed. If the task is tuition, fees will automatically be added to the tutee's fee balance. - -=== Edit task `[coming in v1.2]` -Edits date, time, duration or description of an existing task. - -=== Delete task `[coming in v1.2]` +=== Delete task `[coming in v1.3]` Deletes an existing task. -=== View task `[coming in v1.2]` +=== View task `[coming in v1.3]` Views a list of tasks. === View sort `[coming in v1.2]` @@ -307,9 +293,15 @@ Views a sorted list of people or task based on a user specified sorting criterio Views the calender, which will display the month or week based on the user input. When viewing in week, timeline of each day of the week will be shown and task in a specific time slot will be shown. -=== Update tutee fees `[coming in v1.3]` +=== Update tutee fees `[coming in v1.4]` Updates the remaining balance of the fees of a specific tutee after he or she has paid. +=== Complete task `[coming in v2.0]` +Marks a task as completed. If the task is tuition, fees will automatically be added to the tutee's fee balance. + +=== Edit task `[coming in v2.0]` +Edits date, time, duration or description of an existing task. + // tag::dataencryption[] === Encrypting data files `[coming in v2.0]` @@ -326,6 +318,8 @@ _{explain how the user can enable/disable data encryption}_ Using Command Word: + * *Add* `add n/NAME p/PHONE_NUMBER e/EMAIL a/ADDRESS [t/TAG]...` + e.g. `add n/James Ho p/22224444 e/jamesho@example.com a/123, Clementi Rd, 1234665 t/friend t/colleague` + +* *Add Tutee* `addtutee n/NAME p/PHONE_NUMBER e/EMAIL a/ADDRESS s/SUBJECT g/GRADE edu/EDUCATION_LEVEL sch/SCHOOL [t/TAG]...` + +e.g. `add n/James Ho p/22224444 e/jamesho@example.com a/123, Clementi Rd, 1234665 s/Mathematics g/A edu/junior college sch/National Junior College t/priority` + * *Clear* : `clear` + * *Delete* : `delete INDEX` + e.g. `delete 3` + diff --git a/src/main/java/seedu/address/model/AddressBook.java b/src/main/java/seedu/address/model/AddressBook.java index 2214b69fe0b0..50bd935dbd3f 100644 --- a/src/main/java/seedu/address/model/AddressBook.java +++ b/src/main/java/seedu/address/model/AddressBook.java @@ -134,10 +134,10 @@ private Person syncWithMasterTagList(Person person) { personTags.forEach(tag -> correctTagReferences.add(masterTagObjects.get(tag))); if (person instanceof Tutee) { - return new Tutee(person.getName(), person.getPhone(), person.getEmail(), person.getAddress(), - ((Tutee) person).getSubject(), ((Tutee) person).getGrade(), - ((Tutee) person).getEducationLevel(), - ((Tutee) person).getSchool(), correctTagReferences); + return new Tutee(person.getName(), person.getPhone(), person.getEmail(), person.getAddress(), ( + (Tutee) person).getSubject(), ((Tutee) person).getGrade(), ( + (Tutee) person).getEducationLevel(), ( + (Tutee) person).getSchool(), correctTagReferences); } else { return new Person( person.getName(), person.getPhone(), person.getEmail(), person.getAddress(), correctTagReferences); diff --git a/src/main/java/seedu/address/ui/BrowserPanel.java b/src/main/java/seedu/address/ui/BrowserPanel.java index bb0d61380d5a..6cf4492b8078 100644 --- a/src/main/java/seedu/address/ui/BrowserPanel.java +++ b/src/main/java/seedu/address/ui/BrowserPanel.java @@ -22,7 +22,7 @@ public class BrowserPanel extends UiPart { public static final String DEFAULT_PAGE = "default.html"; public static final String SEARCH_PAGE_URL = - "https://se-edu.github.io/addressbook-level4/DummySearchPage.html?name="; + "http://www.google.com.sg/search?q="; private static final String FXML = "BrowserPanel.fxml"; diff --git a/src/test/java/seedu/address/logic/commands/AddPersonalTaskCommandTest.java b/src/test/java/seedu/address/logic/commands/AddPersonalTaskCommandTest.java index e3db97ae8294..8e354e684b96 100644 --- a/src/test/java/seedu/address/logic/commands/AddPersonalTaskCommandTest.java +++ b/src/test/java/seedu/address/logic/commands/AddPersonalTaskCommandTest.java @@ -1,6 +1,6 @@ package seedu.address.logic.commands; -import static org.junit.Assert.assertEquals; +import static junit.framework.TestCase.assertEquals; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; @@ -11,7 +11,6 @@ import java.time.LocalDateTime; import java.time.format.DateTimeFormatter; import java.time.format.ResolverStyle; - import java.util.ArrayList; import org.junit.Rule; @@ -40,18 +39,18 @@ public void constructor_nullTask_throwsNullPointerException() { thrown.expect(NullPointerException.class); new AddPersonalTaskCommand(null); } - /** + @Test - public void execute_validPersonalTask_addSuccessful() throws Exception { + public void execute_validPersonalTask_addSuccessful() { ArrayList taskListCopy = Schedule.getTaskList(); ArrayList personalTaskListCopy = PersonalSchedule.getPersonalTaskList(); + PersonalTask task = new PersonalTask(taskDateTime, VALID_DURATION, VALID_TASK_DESC); AddPersonalTaskCommand command = new AddPersonalTaskCommand(task); - CommandResult commandResult = command.execute(); + CommandResult commandResult = command.executeUndoableCommand(); assertEquals(AddPersonalTaskCommand.MESSAGE_SUCCESS, commandResult.feedbackToUser); - * NullPointerException thrown. Do you know what's wrong? //taskList should be updated taskListCopy.add(task); assertEquals(taskListCopy, Schedule.getTaskList()); @@ -59,23 +58,22 @@ public void execute_validPersonalTask_addSuccessful() throws Exception { //personalTaskList should be updated personalTaskListCopy.add(task); assertEquals(personalTaskListCopy, PersonalSchedule.getPersonalTaskList()); - } - */ + @Test public void equals() { LocalDateTime taskDateTime2 = LocalDateTime.parse("08/08/1988 18:00", formatter); PersonalTask task2 = new PersonalTask(taskDateTime2, VALID_DURATION, VALID_TASK_DESC); AddPersonalTaskCommand addFirstTask = new AddPersonalTaskCommand(task); - AddPersonalTaskCommand addFirstTaskcopy = new AddPersonalTaskCommand(task); + AddPersonalTaskCommand addFirstTaskCopy = new AddPersonalTaskCommand(task); AddPersonalTaskCommand addSecondTask = new AddPersonalTaskCommand(task2); // same object -> returns true assertTrue(addFirstTask.equals(addFirstTask)); // same values -> returns true - assertTrue(addFirstTask.equals(addFirstTaskcopy)); + assertTrue(addFirstTask.equals(addFirstTaskCopy)); // different types -> returns false assertFalse(addFirstTask.equals(1));