From e4256cb5e4a610b1d52cbf14eb177f2ca3fceca2 Mon Sep 17 00:00:00 2001 From: solomonng2001 Date: Tue, 26 Mar 2024 21:03:10 +0800 Subject: [PATCH 1/4] Enable assertions --- build.gradle | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/build.gradle b/build.gradle index 7860b64df1b..8d6d10441ab 100644 --- a/build.gradle +++ b/build.gradle @@ -70,3 +70,7 @@ shadowJar { } defaultTasks 'clean', 'test' + +run { + enableAssertions = true +} From d93ddfba01a0dd82914418efed27304886e0fe7f Mon Sep 17 00:00:00 2001 From: getsquared Date: Wed, 27 Mar 2024 02:19:05 +0800 Subject: [PATCH 2/4] Update UG --- docs/UserGuide.md | 230 ++++++++++++++++++++++++---------------------- 1 file changed, 120 insertions(+), 110 deletions(-) diff --git a/docs/UserGuide.md b/docs/UserGuide.md index b2b7252c2c6..95226ceeddf 100644 --- a/docs/UserGuide.md +++ b/docs/UserGuide.md @@ -27,8 +27,7 @@ Ready to head straight into the action? You can refer to our [Quick Start](#quic
## Using this guide -This guide walks you through all the features of ClientCare and can be used as a quick reference whenever you need any help. If you're just getting started with ClientCare, we welcome you to start from our [Introduction](#introduction) section to -learn more about the app. For setting up ClientCare, you might find the [Quick Start](#quick-start) section helpful. +This guide walks you through all the features of ClientCare and can be used as a quick reference whenever you need any help. If you're just getting started with ClientCare, we welcome you to start from our [Introduction](#introduction) section to learn more about the app. For setting up ClientCare, you might find the [Quick Start](#quick-start) section helpful. Ready to use ClientCare? You can check out our [Features](#features) section. For ease of reference, the [Features](#features) section is divided into subsections corresponding to each main feature: @@ -42,18 +41,39 @@ You can also refer to our [Table of Contents](#table-of-contents) to navigate be #### Who is this guide for? This guide does not assume any technical knowledge from users. Typing on a keyboard is all you need to know! -ClientCare uses a [Command Line Interface (CLI)](#cli) to interact with users. Not sure what CLI is? No worries, we got you covered. -You can head over to the [CLI Introduction](#command-line-interface-introduction) for a quick breakdown. +ClientCare uses a Text Command Box to interact with users. Not sure how to use it? No worries, we got you covered. +You can head over to the [Text Command Introduction](#text-commands-introduction) for a quick breakdown. -If you are familiar with how CLI works, good news! Using ClientCare will be a breeze for you. +If you are familiar with how text commands work, good news! Using ClientCare will be a breeze for you. #### Conventions used in this guide -**Formatting Conventions** +**Formatting Conventions**
+As you read through the guide, you might come across different text formats, and wonder what they mean. Here is a quick rundown of the conventions we use! -**Command Format Conventions** +| Format | Description | +|------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| [blue hyperlink](https://ay2324s2-cs2103t-w12-1.github.io/tp/UserGuide.html) | Blue hyperlinks bring you to another section of the user guide or another website for more relevant information. | +| `command` | Text in a monospace font and grey box are ClientCare commands. Refer to [ClientCare Commands](#clientcare-commands) for more details. | | +| `FIELD` | Upper case text in a monospace font are fields to input with ClientCare commands. Each command has unique fields, which you can find under [Features](#features). | -**Call-out Text-box Conventions** +**Call-out Text-box Conventions**
+You might encounter these call-outs while reading through the guide, which contain additional information for using ClientCare. + + + +**Tip:** Tip call-outs like this contain helpful pointers for using ClientCare! + + + + +**Note:** Information call-outs like this contain information about ClientCare you should take note of! + + + + +**CAUTION**: Caution call-outs like this contain warnings you should remember when using ClientCare to avoid errors! + -------------------------------------------------------------------------------------------------------------------- @@ -95,7 +115,7 @@ Let's get started with ClientCare. This section will help you get familiar with Don't have ClientCare installed on your computer yet? Check out our step-by-step installation instructions to download ClientCare. -1. ClientCare is written in the programming language Java, so you'll need **Java 11 or above** installed in your computer to run Clientcare. +1. ClientCare is written in the programming language Java, so you'll need **Java 11 or above** installed in your computer to run ClientCare. 1. Not sure if you have a compatible Java version installed on your computer? Windows or macOS users might find [this guide](https://blog.hubspot.com/website/check-java-verison) useful. While Linux users can refer to [this guide](https://phoenixnap.com/kb/check-java-version-linux). @@ -106,7 +126,11 @@ download ClientCare. ![Tag](images/ug/ReleaseTag%20v1.2.jpg =600x) -==The JAR file can be found at the bottom of the page== + + +**Note:** The ClientCare application file can be found at the bottom of the release notes, under Assets! + + ![jar](images/ug/clientcare%20jar%20file%20v1.2.jpg =600x) 4. Create a new empty folder (with any name you like) in your computer where you'd like to store ClientCare. @@ -158,23 +182,22 @@ These are the platforms we currently support ClientCare on: --------------------------------------------------------------------------------------------------------------------
-## Getting familiar with ClientCare's interface -Now that we got ClientCare up and running, let's get you familiar with its user interface. +## Getting familiar with ClientCare's display +Now that we got ClientCare up and running, let's get you familiar with its display. You will learn how the different parts of ClientCare look and work in this section. -#### ClientCare's GUI Components +#### ClientCare's Display Components -ClientCare has **6** components in its GUI. Different commands affect parts of the GUI. -You can refer to the [Quick Tutorial](#quick-tutorial) to see how the different parts of the GUI change when entering commands! +ClientCare has **6** components in its GUI. Different commands affect parts of the Display. +You can refer to the [Quick Tutorial](#quick-tutorial) to see how the different parts of the display change when entering commands! -![GUI](images/ug/GUI%20v1.2%20Graphic.png) +![Display](images/ug/GUI%20v1.2%20Graphic.png)
-#### Command Line Interface Introduction -ClientCare works through the Command Line Interface (CLI). Instead of clicking buttons, you tell ClientCare what to do by typing! -These texts sent to ClientCare are known as commands. +#### Text Commands Introduction +ClientCare works through text commands. Instead of clicking buttons, you tell ClientCare what to do by typing! These commands must be formatted in a specific way or ClientCare will not understand what you are saying. Let's learn the language that ClientCare speaks in. @@ -184,28 +207,34 @@ Let's learn the language that ClientCare speaks in. ### ClientCare Commands A ClientCare command has the following parts: -##### 1)Command Keyword +##### 1) Command Keyword This keyword tells ClientCare what you want to do. If you want to add a new client, then `add` will be the keyword. All commands must start with a keyword. -##### 2)Index -Some commands may involve an index. This is simply a number which is assigned to a particular Client or Policy. +##### 2) Index +Some commands may involve an index, indicated in command formats as `INDEX`. This is simply a number which is assigned to a particular Client. For example, the first client in the list will have the index `1`. -##### 3)Command Parameters -Parameters are fields or variables that are associated with some commands. For example, when you are adding a client, you need to add his name too. -His name will be considered a parameter, similarly for Date of Birth and Address etc. +##### 3) Command Fields +Some commands have fields associated with them. For example, when you are adding a client, you need to add his name too. +His name will be considered a field, similarly for Date of Birth, Address etc. +Here are some things to take note of when using them! +* Fields often have a prefix in front of them. For example, name has `n/` and date has `d/`. The command format will show what field a prefix is referring to in uppercase, like `n/NAME`, in case you forget! +* Some fields are even optional, and they'll be shown with square brackets: `[a/ADDRESS]`. +* Fields that have a trailing ellipsis behind them like `[t/TAG]...`, meaning you can use multiple of them, so you can have both `t/friend t/drives` in one command. +* Not all commands have fields! For example, when clearing your client list, a simple command keyword of `clear` will do! There is no need to have a parameter such as `clear 1` or `clear 2`. -Parameters often have a prefix in front of them. For example, name has `n/` and date has `d/`. +The full list of commands and their formats can be found under the [Features](#features) section. +Alternatively, [Command Summary](#command-summary) has all of them under one page for a quick reference. + -Not all commands have parameters! For example, when clearing your client list, a simple command keyword of `clear` will do! -There is no need to have a parameter such as `clear 1` or `clear 2`. +**CAUTION**: If you are using a PDF version of this document, be careful when copying and pasting commands that span multiple lines as the command format may be copied over incorrectly. + +
-The full list of commands and their formats can be found under the [Features](#features) section. -Alternatively, [Command Summary](#command-summary) has all of them under one page for a quick reference. --------------------------------------------------------------------------------------------------------------------
@@ -226,29 +255,6 @@ For easy reference, similar features are grouped into the same subsections as sh * [Policy related commands](#policy-related-commands) * [Miscellaneous](#miscellaneous) -
-
- -**Notes about the command format:**
- -* Words in `UPPER_CASE` are the parameters to be supplied by the user.
- e.g. in `add n/NAME`, `NAME` is a parameter which can be used as `add n/John Doe`. - -* Items in square brackets are optional.
- e.g. `n/NAME [t/TAG]` can be used as `n/John Doe t/friend` or as `n/John Doe`. - -* Items with `…`​ after them can be used multiple times including zero times.
- e.g. `[t/TAG]…​` can be used as ` ` (i.e. 0 times), `t/friend`, `t/friend t/family` etc. - -* Parameters can be in any order.
- e.g. if the command specifies `n/NAME c/PHONE_NUMBER`, `c/PHONE_NUMBER n/NAME` is also acceptable. - -* Extraneous parameters for commands that do not take in parameters (such as `help`, `list`, `exit` and `clear`) will be ignored.
- e.g. if the command specifies `help 123`, it will be interpreted as `help`. - -* If you are using a PDF version of this document, be careful when copying and pasting commands that span multiple lines as space characters surrounding line-breaks may be omitted when copied over to the application. -
-

@@ -261,7 +267,7 @@ details, so you never have to lose a contact again. ClientCare offers the following commands to help you manage your clients: * [Adding a client: `add`](#adding-a-client-add) * [Listing all clients: `list`](#listing-all-clients-list) -* [Viewing a client: `view`](#view-a-client-view) +* [Viewing a client: `view`](#viewing-a-client-view) * [Editing a client: `edit`](#editing-a-client-edit) * [Finding a client: `find`](#locating-client-by-name-find) * [Deleting a client: `delete`](#deleting-a-client-delete) @@ -275,22 +281,22 @@ Got a new client? You can add a client to the client list with `add`. Format: `add n/NAME c/PHONE_NUMBER e/EMAIL a/ADDRESS b/BIRTHDAY p/PRIORITY [t/TAG]…​` - + -**Tip:** A client can have any number of tags (including 0). All other parameters (with the exception of tags) cannot have duplicate parameters. +**Note:** A client can have any number of tags (including 0). All other fields (with the exception of tags) cannot have duplicate parameters. -Parameters usage for client details: +Fields usage for client details: -| Parameter | Usage | Example | -|-------------|-----------------------------------------------------------------------------------------|---------------------------------| -| 'n/NAME' | All names in the system must be unique | `n/John Doe` | +| Field | Usage | Example | +|------------------|------------------------------------------------------------------------------------|---------------------------------| +| 'n/NAME' | All names in the system must be unique | `n/John Doe` | | 'c/PHONE_NUMBER' | Phone numbers should only contain numbers, and it should be at least 3 digits long | `c/98765432` | -| 'e/EMAIL' | Email should be in the format of `local-part@domain` | `e/johndoe@email.com` | -| 'a/ADDRESS' | Address can take any text value | `a/311, Clementi Ave 2, #02-25` | -| 'b/BIRTHDAY'| Birthday should be in the format of `YYYY-MM-DD` | `b/1990-01-01` | -| 'p/PRIORITY'| Priority can be `low`, `medium`, `high` or `vip` | `p/medium` | -| 't/TAG' | Tags can be any text value | `t/friends` | +| 'e/EMAIL' | Email should be in the format of `local-part@domain` | `e/johndoe@email.com` | +| 'a/ADDRESS' | Address can take any text value | `a/311, Clementi Ave 2, #02-25` | +| 'b/BIRTHDAY' | Birthday should be in the format of `YYYY-MM-DD` | `b/1990-01-01` | +| 'p/PRIORITY' | Priority can be `low`, `medium`, `high` or `vip` | `p/medium` | +| 't/TAG' | Tags can be any text value | `t/friends` | Examples: * `add n/John Doe c/98765432 e/johnd@example.com a/311, Clementi Ave 2, #02-25 b/1990-01-01 p/low t/friends t/owesMoney` @@ -301,30 +307,19 @@ Examples:
-### Listing all clients : `list` - -Want to see all your clients? -`list` shows a list of all your clients in the client list. - -Format: `list` - -
-
- -### View a client : `view` +### Deleting a client : `delete` -You can view a client's details and his policies with `view`. -The `view` command shows the particulars and policies of a client. +You can delete a specified client from the client list with `delete`. -Format: `view INDEX` +Format: `delete INDEX` -* Views the client at the specified `INDEX`. +* Deletes the client at the specified `INDEX`. * The index refers to the index number shown in the displayed client list. * The index **must be a positive integer** 1, 2, 3, …​ Examples: -* `list` followed by `view 2` views the 2nd client in the client list. -* `find Betsy` followed by `view 1` view the 1st client in the results of the `find` command. +* `list` followed by `delete 2` deletes the 2nd client in the client list. +* `find Betsy` followed by `delete 1` deletes the 1st client in the results of the `find` command.

@@ -340,7 +335,7 @@ Format: `edit INDEX [n/NAME] [p/PHONE] [e/EMAIL] [a/ADDRESS] [b/BIRTHDAY] [p/PRI * Existing values will be updated to the input values. * When editing tags, the existing tags of the client will be removed i.e adding of tags is not cumulative. * You can remove all the client’s tags by typing `t/` without - specifying any tags after it. + specifying any tags after it. * Refer to the [Adding a client](#adding-a-client-add) section for the usage of the parameters. Examples: @@ -350,6 +345,35 @@ Examples:

+### Listing all clients : `list` + +Want to see all your clients? +`list` shows a list of all your clients in the client list. + +Format: `list` + +
+
+ + +### Viewing a client : `view` + +You can view a client's details and his policies with `view`. +The `view` command shows the particulars and policies of a client. + +Format: `view INDEX` + +* Views the client at the specified `INDEX`. +* The index refers to the index number shown in the displayed client list. +* The index **must be a positive integer** 1, 2, 3, …​ + +Examples: +* `list` followed by `view 2` views the 2nd client in the client list. +* `find Betsy` followed by `view 1` view the 1st client in the results of the `find` command. + +
+
+
### Locating client by name: `find` @@ -359,34 +383,22 @@ Client whose names contain any of the given keywords will show up! Format: `find KEYWORD [MORE_KEYWORDS]` -* The search is case-insensitive. e.g `hans` will match `Hans` -* The order of the keywords does not matter. e.g. `Hans Bo` will match `Bo Hans` +* The search is case-insensitive. e.g `hans` will match `Hans`. +* The order of the keywords does not matter. e.g. `Hans Bo` will match `Bo Hans`. * Only the name is searched. -* Only full words will be matched e.g. `Han` will not match `Hans` +* Only full words will be matched e.g. `Han` will not match `Hans`. * client matching at least one keyword will be returned (i.e. `OR` search). - e.g. `Hans Bo` will return `Hans Gruber`, `Bo Yang` + e.g. `Hans Bo` will return `Hans Gruber`, `Bo Yang`. Examples: * `find John` returns `john` and `John Doe` * `find alex david` returns `Alex Yeoh`, `David Li`
![result for 'find alex david'](images/findAlexDavidResult.png =600x) -
-
- -### Deleting a client : `delete` - -You can delete a specified client from the client list with `delete`. - -Format: `delete INDEX` - -* Deletes the client at the specified `INDEX`. -* The index refers to the index number shown in the displayed client list. -* The index **must be a positive integer** 1, 2, 3, …​ + -Examples: -* `list` followed by `delete 2` deletes the 2nd client in the client list. -* `find Betsy` followed by `delete 1` deletes the 1st client in the results of the `find` command. +**Tip:** You can use `find` to more easily find the client you want for commands that require a client `INDEX`! +

@@ -399,8 +411,7 @@ Format: `clear` - **CAUTION:** -Clearing is irreversible and will NOT have a confirmation screen +**CAUTION**: Clearing is irreversible and will NOT have a confirmation screen
@@ -559,12 +570,11 @@ ClientCare data are saved in the hard disk automatically after any command that ### Editing the data file -ClientCare data is automatically saved as a JSON file `[JAR file location]/data/clientcare.json`. Advanced users are welcome to update data directly by editing that data file. +ClientCare data is automatically saved as a file `[ClientCare file location]/data/clientcare.json`. Advanced users are welcome to update data directly by editing that data file. - **CAUTION:** -If your changes to the data file makes its format invalid, ClientCare will discard all data and start with an empty data file at the next run. Hence, it is recommended to take a backup of the file before editing it.
+**CAUTION**: If your changes to the data file makes its format invalid, ClientCare will discard all data and start with an empty data file at the next run. Hence, it is recommended to take a backup of the file before editing it.
Furthermore, certain edits can cause the ClientCare to behave in unexpected ways (e.g., if a value entered is outside the acceptable range). Therefore, edit the data file only if you are confident that you can update it correctly.
@@ -595,7 +605,7 @@ _Details coming soon ..._ # Known issues
-1. **When using multiple screens**, if you move the application to a secondary screen, and later switch to using only the primary screen, the GUI will open off-screen. The remedy is to delete the `preferences.json` file created by the application before running the application again. +1. **When using multiple screens**, if you move the application to a secondary screen, and later switch to using only the primary screen, the application will open off-screen. The remedy is to delete the `preferences.json` file created by the application before running the application again. --------------------------------------------------------------------------------------------------------------------
@@ -605,12 +615,12 @@ _Details coming soon ..._ | Action | Format, Examples | |------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | [**Add**](#adding-a-client-add) | `add n/NAME c/PHONE_NUMBER e/EMAIL a/ADDRESS b/BIRTHDAY p/PRIORITY [t/TAG]…​`
e.g.`add n/James Ho p/22224444 e/jamesho@example.com a/123, Clementi Rd, 1234665 b/1990-01-01 p/medium t/friend t/colleague` | -| [**Clear**](#clear) | `clear` | | [**Delete**](#deleting-a-client-delete) | `delete INDEX`
e.g. `delete 3` | | [**Edit**](#editing-a-client-edit) | `edit INDEX [n/NAME] [p/PHONE] [e/EMAIL] [a/ADDRESS] [b/BIRTHDAY] [p/PRIORITY] [t/TAG]…​`
e.g.`edit 2 n/James Lee e/jameslee@example.com` | +| [**List**](#listing-all-clients-list) | `list` | | [**View**](#viewing-a-client-view) | `view INDEX`
e.g, `view 1` | | [**Find**](#finding-a-client-find) | `find KEYWORD [MORE_KEYWORDS]`
e.g. `find James Jake` | -| [**List**](#listing-all-clients-list) | `list` | +| [**Clear**](#clearing-all-entries-clear) | `clear` | | [**LastMet**](#updating-last-met-met) | `met INDEX [l/DATE]`
e.g. `met 2 l/2023-05-07` | | [**Schedule**](#scheduling-appointments-schedule) | `schedule INDEX [s/DATETIME]`
e.g. `schedule 2 s/2023-05-07 22:00` | | | [**Add Policy**](#adding-a-policy-addpolicy) | `addpolicy INDEX n/POLICY_NAME i/POLICY_ID`
e.g. `addpolicy 1 n/Life i/1` | From c6419191a4e24e3d3f0e96a339562349716772d5 Mon Sep 17 00:00:00 2001 From: getsquared Date: Wed, 27 Mar 2024 02:21:53 +0800 Subject: [PATCH 3/4] Update UG command summary --- docs/UserGuide.md | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/docs/UserGuide.md b/docs/UserGuide.md index 95226ceeddf..c64ad7dfba5 100644 --- a/docs/UserGuide.md +++ b/docs/UserGuide.md @@ -581,11 +581,6 @@ Furthermore, certain edits can cause the ClientCare to behave in unexpected ways

-### Archiving data files `[coming in v2.0]` - -_Details coming soon ..._ - -
--------------------------------------------------------------------------------------------------------------------
@@ -623,6 +618,7 @@ _Details coming soon ..._ | [**Clear**](#clearing-all-entries-clear) | `clear` | | [**LastMet**](#updating-last-met-met) | `met INDEX [l/DATE]`
e.g. `met 2 l/2023-05-07` | | [**Schedule**](#scheduling-appointments-schedule) | `schedule INDEX [s/DATETIME]`
e.g. `schedule 2 s/2023-05-07 22:00` | | +| [**Mark**](#marking-appointments-mark) | `mark INDEX`
e.g. `mark 2` | | | [**Add Policy**](#adding-a-policy-addpolicy) | `addpolicy INDEX n/POLICY_NAME i/POLICY_ID`
e.g. `addpolicy 1 n/Life i/1` | | [**Delete Policy**](#deleting-a-policy-deletepolicy) | `deletepolicy INDEX i/POLICY_ID`
e.g. `deletepolicy 1 i/1` | | [**Help**](#viewing-help-help) | `help` | From 354e7707c661840118a8890d2532f5067167c3d4 Mon Sep 17 00:00:00 2001 From: getsquared Date: Wed, 27 Mar 2024 02:24:56 +0800 Subject: [PATCH 4/4] Remove blue text --- docs/UserGuide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/UserGuide.md b/docs/UserGuide.md index c64ad7dfba5..b5e81d46374 100644 --- a/docs/UserGuide.md +++ b/docs/UserGuide.md @@ -159,7 +159,7 @@ These are the platforms we currently support ClientCare on: #### For Windows 1. To start ClientCare, simply open up the folder where your downloaded `clientcare.jar`. -2. Next, click on the Address Bar as shown below. It should turn !!#b#blue##!! upon clicking. +2. Next, click on the Address Bar as shown below. It should turn !!blue!! upon clicking. ![folder](images/ug/windows%20saveDirectory.png =600x) 3. Type 'powershell' into the Address Bar and press ENTER on your keyboard