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

Final dg touchup #347

Merged
merged 3 commits into from
Nov 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 25 additions & 8 deletions docs/DeveloperGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ The `Model` component,
The `Storage` component:
* can save both address book data and user preference data in JSON format, and read them back into corresponding objects.
* inherits from both `AgentAssistStorage` and `UserPrefStorage`, which means it can be treated as either one (if only the functionality of only one is needed).
* depends on some classes in the `Model` component (because the `Storage` component's job is to save/retrieve objects that belong to the `Model`)
* depends on some classes in the `Model` component (because the `Storage` component's job is to save/retrieve objects that belong to the `Model`).

### Common classes

Expand Down Expand Up @@ -515,10 +515,12 @@ Priorities: High (must have) - `* * *`, Medium (nice to have) - `* *`, Low (unli
**Extensions:**

* 1a. A provided flag is invalid.

* 1a1. AgentAssist shows an invalid parameter error message.

Use case resumes at step 1.
* 1b. A provided value is invalid.

* 1b1. AgentAssist shows the error pertaining to the invalid field.

Use case resumes at step 1.
Expand All @@ -536,15 +538,18 @@ Priorities: High (must have) - `* * *`, Medium (nice to have) - `* *`, Low (unli
**Extensions:**

* 1a. A provided flag is invalid.

* 1a1. AgentAssist shows an invalid parameter error message.

Use case resumes at step 1.
* 1b. A provided value is invalid.

* 1b1. AgentAssist shows the error pertaining to the invalid field.

Use case resumes at step 1.

* 1c. No clients in the existing data pass the filter.

* 1c1. AgentAssist shows a blank list.

Use case ends.
Expand All @@ -564,20 +569,24 @@ Priorities: High (must have) - `* * *`, Medium (nice to have) - `* *`, Low (unli
**Extensions:**

* 3a. The provided client index is invalid.

* 3a1. AgentAssist shows an invalid index error message.

Use case resumes at step 3.

* 3b. A provided flag is invalid.

* 3b1. AgentAssist shows an invalid parameter error message.

Use case resumes at step 3.
* 3c. A provide value is invalid.

* 3c1. AgentAssist shows the error pertaining to the invalid field.

Use case resumes at step 3.

* 3d. Provided values will cause edited client to become a duplicate of an existing client.

* 3d1. AgentAssist shows an error to inform the user that allowing this edit will result in a duplicate client.
* 3d2. No change occurs.

Expand All @@ -597,6 +606,7 @@ Priorities: High (must have) - `* * *`, Medium (nice to have) - `* *`, Low (unli
**Extensions:**

* 3a. The provided client index is invalid.

* 3a1. AgentAssist shows an invalid index error message.

Use case resumes at step 3.
Expand Down Expand Up @@ -624,6 +634,7 @@ Priorities: High (must have) - `* * *`, Medium (nice to have) - `* *`, Low (unli
**Extensions:**

* 3a. User declines confirmation.

* 3a1. AgentAssist shows cancellation message to user.
* 3a2. No change is made.

Expand All @@ -640,6 +651,7 @@ Priorities: High (must have) - `* * *`, Medium (nice to have) - `* *`, Low (unli
**Extensions:**

* 2a. There was no recorded last change.

* 2a1. AgentAssist shows an error message to user.
* 2a2. No change is made.

Expand Down Expand Up @@ -711,15 +723,16 @@ testers are expected to do more *exploratory* testing.

1. Initial launch

1. Download the jar file and copy into an empty folder
1. Download the jar file and copy into an empty folder.

1. Double-click the jar file Expected: Shows the GUI with a set of sample contacts. The window size may not be optimum.
2. Run the jar file using terminal.<br>
Expected: Shows the GUI with a set of sample contacts. The window size may not be optimum.

1. Saving window preferences
2. Saving window preferences

1. Resize the window to an optimum size. Move the window to a different location. Close the window.

1. Re-launch the app by double-clicking the jar file.<br>
2. Re-launch the app by running the jar file through terminal.<br>
Expected: The most recent window size and location is retained.

### Adding a client
Expand Down Expand Up @@ -771,6 +784,7 @@ testers are expected to do more *exploratory* testing.
### Editing a client

1. Editing a client while all clients are being shown

1. Prerequisites: List all clients using the `list` command. At least one client in the list.

2. Test case: `edit 1 n/ <NAME>`<br>
Expand Down Expand Up @@ -798,6 +812,7 @@ testers are expected to do more *exploratory* testing.
2. Functions similar to above example except that the indexes to be used are based on the new list shown.

### Filter for clients

1. Filtering for a client based on a criteria

1. Test case: `filter n/ <NAME>`<br>
Expand All @@ -821,6 +836,7 @@ testers are expected to do more *exploratory* testing.
Expected: Similar to previous.

### Viewing a client

1. Viewing a client while all clients are being shown

1. Prerequisites: List all clients using the `list` command. At least one client in the list.
Expand All @@ -838,6 +854,7 @@ testers are expected to do more *exploratory* testing.
2. Functions similar to above example except that the indexes to be used are based on the new list shown.

### Closing the detailed view of a client

1. Closing the view of the currently viewed client

1. Prerequisites: The detailed view of a client is currently open.
Expand Down Expand Up @@ -879,9 +896,9 @@ For example, we added a custom `help` window with an image-based command layout,
- `view` and `close` Commands: Implementing these commands with JavaFX’s split-pane required careful lifecycle management of UI components, handling divider positions and proportions. To maintain consistency between the list and detail views, we used a `ListChangeListener` class to track client list updates and handle cases such as clients being deleted, edited, or filtered out. This entailed intricate event handling and managing multiple change types to keep UI elements synchronized.


- Status Pie Chart: Implementing this feature involved tracking real-time status changes in the client list. We used an observer pattern to handle updates and ensured concurrent modifications ran safely by using `Platform.runLater()`. Extensive CSS customization supported dark theme compatibility, and the design featured color-coded status categories (`NA`, `NON_URGENT`, `URGENT`) with custom legends. Performance optimization was key, as frequent updates could impact UI performance. We employed efficient data structures to track status counts, minimizing redraws and maintaining smooth operation.
- `Status Pie Chart`: Implementing this feature involved tracking real-time status changes in the client list. We used an observer pattern to handle updates and ensured concurrent modifications ran safely by using `Platform.runLater()`. Extensive CSS customization supported dark theme compatibility, and the design featured color-coded status categories (`NA`, `NON_URGENT`, `URGENT`) with custom legends. Performance optimization was key, as frequent updates could impact UI performance. We employed efficient data structures to track status counts, minimizing redraws and maintaining smooth operation.

Both the `view`/`close` commands and the `Status` Pie Chart required extensive testing to ensure they operated robustly under various conditions, with a clean code structure and separation of concerns.
Both the `view`/`close` commands and the `Status Pie Chart` required extensive testing to ensure they operated robustly under various conditions, with a clean code structure and separation of concerns.

Overall, we estimate a 35% increase in base functionality from the AB3 system, due to additional features and the increased complexity of components such as `filter`, `view`/`close` commands, and `Status` Pie Chart. The `Parser` and `Predicate` classes also grew significantly in complexity to accommodate these enhancements.
Overall, we estimate a 35% increase in base functionality from the AB3 system, due to additional features and the increased complexity of components such as `filter`, `view`/`close` commands, and `Status Pie Chart`. The `Parser` and `Predicate` classes also grew significantly in complexity to accommodate these enhancements.

4 changes: 2 additions & 2 deletions docs/UserGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ Case statuses are also color-coded and appear next to a client’s name in the l

<span style="color: #C46210; font-size: 16px;">⬤</span> Non-Urgent Status

Clients with **NA** status (no follow-up required) have no status label on the UI but are represented in green (<span style="color: #009E60; font-size: 18px;">⬤</span>) on the status pie chart to indicate that their cases are resolved or need no attention.
Clients with **NA** status (no follow-up required) have no status label on the UI but are represented in green (<span style="color: #009E60; font-size: 16px;">⬤</span>) on the status pie chart to indicate that their cases are resolved or need no attention.

[↑ Return to Table of Contents](#table-of-contents)

Expand Down Expand Up @@ -273,7 +273,6 @@ add n/ John Doe e/ [email protected]
* **Arguments:** `John Doe` and `[email protected]` are the actual values being input for the respective flags.
* **Note:** This command is provided as an example for learning purposes only. Additional mandatory flags are needed to make it fully functional, which will be explained in the sections that follow.

<div style="page-break-after: always;"></div>

## 5.2 Commands
A command is the action that AgentAssist will perform, such as adding, deleting, or editing a client's contact.
Expand Down Expand Up @@ -1028,6 +1027,7 @@ Each credit card tier and client status is visually distinguished in the UI with
5. **Using non-English text input can cause bugs**. This release fully supports only standard English text input and does not support the extended Latin alphabet or non-English characters. Using accented characters (e.g., é, ñ), non-Latin scripts (e.g., Chinese), or right-to-left text (e.g., Arabic) may lead to unexpected behavior, including display issues, data processing errors, or even command parsing failures. Expanded support for international characters and languages is planned for future releases.
6. **For index based commands**, negative inputs and inputs that are too large result in inconsistent error messages. We are actively working on resolving this inconsistency in future releases.
7. **For the edit command**, edits that do not result in changes to client details are currently considered valid. We are working on adding warnings to notify users of unchanged edits in future releases.
8. **For the Status Pie Chart**, if the application window size is too small, the legend will disappear. We are aware of this, and this is a limitation of JavaFX.

[↑ Return to Table of Contents](#table-of-contents)

Expand Down
Loading