From d68dfcab269a1cda5593b7d9cf5dd63f208d5a62 Mon Sep 17 00:00:00 2001 From: Tang Hao Liang Date: Fri, 5 Apr 2024 18:12:52 +0800 Subject: [PATCH 1/2] Update implementation of grouping for developer guide --- docs/DeveloperGuide.md | 8 ++++++ docs/diagrams/GroupingState3puml | 49 ++++++++++++++++++++++++++++++++ 2 files changed, 57 insertions(+) create mode 100644 docs/diagrams/GroupingState3puml diff --git a/docs/DeveloperGuide.md b/docs/DeveloperGuide.md index c734cb2d8e0..e36e45dc992 100644 --- a/docs/DeveloperGuide.md +++ b/docs/DeveloperGuide.md @@ -198,12 +198,20 @@ Step 3. The user executes `assigngroup gn/2103T gt/Task 1` command to assign a t Step 4. The user executes `addpersontogroup gn/2103T gp/Bob` command to add Bob to the group named "2103T" from the group list. The `addpersontogroup` command calls `Model#addPersonToGroup(String, Person)`, which finds the group with the same name and add the person to the group. + + Step 5. The user executes `removepersonfromgroup gn/2103T gp/4` command to remove Bob from the group named "2103T" from the group list. The `removepersonfromgroup` command calls `Model#removePersonFromGroup(String, Person)`, which finds the group with the same name and remove the person to the group. + + Step 6. The user executes `deletetaskgroup gn/2103T gt/Task 1` command to remove a task named "Task 1" from the group named "2103T" from the group list. The `deletetaskgroup` command calls `Model#deleteAssignedTaskGroup(String, Task)`, which finds the group with the same name and remove that task from everyone that is in the group. + + Step 7. The user executes `deletegroup gn/2103T` command to remove the group from the list. The `deletegroup` command calls `Model#removeGroup(String)`, which finds the group with the same name and remove that group from the list. + + ### \[Proposed\] Undo/Redo Feature The proposed undo/redo mechanism is facilitated by `VersionedAddressBook`. It extends `AddressBook` with an undo/redo history, stored internally as an `addressBookStateList` and `currentStatePointer`. Additionally, it implements the following operations: diff --git a/docs/diagrams/GroupingState3puml b/docs/diagrams/GroupingState3puml new file mode 100644 index 00000000000..f2ccb4ca19c --- /dev/null +++ b/docs/diagrams/GroupingState3puml @@ -0,0 +1,49 @@ +@startuml +!include style.puml +skinparam ClassFontColor #000000 +skinparam ClassBorderColor #000000 +skinparam ClassBackgroundColor #FFFFAA + +title Model + +package Groups { + class Group1 as "2103T:GroupedUniquePersonList" +} + +package Persons { + class Person1 as "Ivan:Person" + class Person2 as "Greg:Person" + class Person3 as "Dave:Person" + class Person4 as "Bob:Person" +} + +Person1 -[hidden]right-> Person2 +Person2 -[hidden]right-> Person3 +Person3 -[hidden]right-> Person4 + +Person1 -up-> Group1 +Person2 -up-> Group1 +Person3 -up-> Group1 +Person4 -up-> Group1 + +package TaskList_Ivan { + class Task1 as "Task 1:Task" +} + +package TaskList_Greg { + class Task2 as "Task 1:Task" +} + +package TaskList_Dave { + class Task3 as "Task 1:Task" +} + +package TaskList_Bob { + class Task4 as "Task 1:Task" +} + + +Task1 -up-> Person1 +Task2 -up-> Person2 +Task3 -up-> Person3 +Task4 -up-> Person4 From b66be5db9a1f041ac44a219336985a5bef8cc1ba Mon Sep 17 00:00:00 2001 From: Tang Hao Liang Date: Fri, 5 Apr 2024 18:31:42 +0800 Subject: [PATCH 2/2] Edit developer guide for UI links --- docs/DeveloperGuide.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/DeveloperGuide.md b/docs/DeveloperGuide.md index 5736c54b575..bf6b1811e1f 100644 --- a/docs/DeveloperGuide.md +++ b/docs/DeveloperGuide.md @@ -67,13 +67,13 @@ The sections below give more details of each component. ### UI component -The **API** of this component is specified in [`Ui.java`](https://github.com/se-edu/addressbook-level3/tree/master/src/main/java/seedu/address/ui/Ui.java) +The **API** of this component is specified in [`Ui.java`](https://github.com/AY2324S2-CS2103T-W13-4/tp/blob/master/src/main/java/seedu/address/ui/Ui.java) The UI consists of a `MainWindow` that is made up of parts e.g.`CommandBox`, `ResultDisplay`, `PersonListPanel`, `StatusBarFooter`, `TaskListPanel` etc. All these, including the `MainWindow`, inherit from the abstract `UiPart` class which captures the commonalities between classes that represent parts of the visible GUI. -The `UI` component uses the JavaFx UI framework. The layout of these UI parts are defined in matching `.fxml` files that are in the `src/main/resources/view` folder. For example, the layout of the [`MainWindow`](https://github.com/se-edu/addressbook-level3/tree/master/src/main/java/seedu/address/ui/MainWindow.java) is specified in [`MainWindow.fxml`](https://github.com/se-edu/addressbook-level3/tree/master/src/main/resources/view/MainWindow.fxml) +The `UI` component uses the JavaFx UI framework. The layout of these UI parts are defined in matching `.fxml` files that are in the `src/main/resources/view` folder. For example, the layout of the [`MainWindow`](https://github.com/AY2324S2-CS2103T-W13-4/tp/blob/master/src/main/java/seedu/address/ui/MainWindow.java) is specified in [`MainWindow.fxml`](https://github.com/AY2324S2-CS2103T-W13-4/tp/blob/master/src/main/resources/view/MainWindow.fxml) The `UI` component,