diff --git a/docs/DeveloperGuide.md b/docs/DeveloperGuide.md index 1193a6142e2..5efee63eb1c 100644 --- a/docs/DeveloperGuide.md +++ b/docs/DeveloperGuide.md @@ -154,22 +154,26 @@ Classes used by multiple components are in the `seedu.addressbook.commons` packa This section describes some noteworthy details on how certain features are implemented. -## Favourite feature and Favourites window +## Favourite/Unfavourite feature and Favourites window -The proposed `favourite` mechanism will make use of a new attribute called `Favourite`. How we went about creating this mechanism is by going through the list of Persons and checking if their `Favourite` instance returns "🌟" (represents favourited) when `toString()` is called. +The proposed Favourite mechanism will make use of a new attribute called `Favourite`. How we went about creating this mechanism is by going through the list of `Person` and checking if their `Favourite` instance returns "🌟" (represents favourited) when `toString()` is called. Given below is an example of how the `favourite` mechanism behaves with the Favourites window. -Step 1. The user starts the application with pre-loaded data of Persons. +Step 1. The user starts the application with pre-loaded data of `Person`. -Step 2. Assuming there is a Person with the index number 1. User then executes `favourite 1` command to favourite the Person with index number 1 in the application. The system will create a new Person with the `Favourite` instance's value set as true. Then calls `Model#setPerson()` to set this Person to be a favourited instance of the same Person. +Step 2. Assuming there is a `Person` with the index number 1 that is not favourited. User then executes `favourite 1` command to favourite the `Person` with index number 1 in the application. The system will create a new `Person` with the `Favourite` instance's value set as true. Then calls `Model#setPerson()` to set this `Person` to be the favourited instance of the same `Person`. -
:bulb: **Note:** -Every newly added Person will have the default value of `False` for `Favourite` attribute, thus will never appear in the Favourites window before the `favourite` command is called on them. -
+ +Step 3. User can access the Favourites window by navigating to the menu item as shown in the diagram, which pops up a new window that contains only those `Persons` that have `Favourite` instance's value set as `True`. The user can also input the command `fw` to open up the Favourites window through this CLI command. -Step 3. User can access the Favourites window by navigating to the menu item as shown in the diagram, which pops up a new window that contains only those Persons that have ‘Favourite’ instance's value set as True. The user can also input the command `fw` to open up the Favourites window through this CLI command. + ## Match feature/Window The `match` opens a new `MatchWindow`, in which all matches are displayed in pairs. @@ -262,14 +266,14 @@ Step 5: The set of `UserImage` is then converted into an `ArrayList` and the fir ## Statistics feature/Window -The `stats` opens a new `StatisticsWindow` that displays a pie chart with the data of the number of sellers & buyers in the 5 different regions, namely {North, South, East, West, Central}. +The `stats` command opens a new Statistics window that displays a pie chart with the data of the number of sellers & buyers in the 5 different regions, namely {North, South, East, West, Central}. This allows the user to be able to visualize his/her client's data to make better business decisions. (exp. Expand the user's influence in the most popular region for any potential sellers/buyers to contact him/her) -**[Future version]**
-Displaying statistics of the number of properties being sold/bought categorized by their room size to provide insight on the most popular number of rooms in a property. -Displaying statistics of the prices of properties sold/bought to provide insight on the average property price sold/bought. -Displaying statistics of lower price and higher price of preferences of clients to provide insight on the average asking price of a property. +**[Future version]**
+* Displaying statistics of the number of properties being sold/bought categorized by their room size to provide insight on the most popular number of rooms in a property. +* Displaying statistics of the prices of properties sold/bought to provide insight on the average property price sold/bought. +* Displaying statistics of lower price and higher price of preferences of clients to provide insight on the average asking price of a property. ## Sorting @@ -348,7 +352,7 @@ RealEstatePro is faster that a typical mouse/GUI driven app that helps the real | High | User | To list out my clients’ information on the app | View all of my clients’ information in one place | | High | User | Differentiate my clients’ on the app (e.g. buyers, sellers) | Know if a client is looking for a property to buy or is trying sell a property | | High | User | Add my clients’ information on the app | Gain access to all these information in one place | -| High | User | Favourite a client | Separate clients based on whose information I frequent the most (favourited) and those that are not | +| High | User | Favourite/Unfavourite a client | Separate clients based on whose information I frequent the most (favourited) and those that are not | | High | User | View favourited clients | Have a compact display of clients that I frequent the most | | High | User | To create a preference for a client who is a buyer | Have information of potential properties that the buyer would want to buy | | High | User | To add properties information of clients who are a seller | Know what kind of property my client is trying to sell so i can see if there is any suitable buyers | @@ -576,7 +580,7 @@ Please bear in mind to extend your testing to more *exploratory* testing after f 3. Test case: `delete 0`
Expected: No client is deleted. Error details shown in the result display. List remains the same. 4. Other incorrect delete commands to try: `delete`, `delete x`, `...` (where x is larger than the list size or smaller than 0) Expected: Similar to previous. -## Favouriting a client +## Favouriting/Unfavouriting a client 1. Favouriting a client while all clients are being shown 1. Prerequisites: List all clients using the `list` command. Multiple clients in the list. @@ -594,7 +598,7 @@ Please bear in mind to extend your testing to more *exploratory* testing after f 2. Open Favourites window by UI - 1. Test case: Click on `files` menu on the top left corner of RealEstatePro. Under the drop-down list, click on `Favourites`.
Expected: The Favourites window will pop up above the listings of clients on the Main window. The window will display a list of clients that are favourited (it will be empty is there are no favourited clients). + 1. Test case: Click on `File` menu on the top left corner of RealEstatePro. Under the drop-down list, click on `Favourites`.
Expected: The Favourites window will pop up above the listings of clients on the Main window. The window will display a list of clients that are favourited (it will be empty is there are no favourited clients). 3. Open Favourites window by key @@ -607,7 +611,7 @@ Please bear in mind to extend your testing to more *exploratory* testing after f 2. Open Statistics window by UI - 1. Test case: Click on `files` menu on the top left corner of RealEstatePro. Under the drop-down list, click on `Stats`.
Expected: The Statistics window will pop up above the listings of clients on the Main window. The window will display a pie chart with data of buyers/sellers in regions based on their preference/properties (If there is no data in RealEstatePro, the pie chart will not be displayed. Labels of the Statistics window will still display). + 1. Test case: Click on `File` menu on the top left corner of RealEstatePro. Under the drop-down list, click on `Stats`.
Expected: The Statistics window will pop up above the listings of clients on the Main window. The window will display a pie chart with data of buyers/sellers in regions based on their preference/properties (If there is no data in RealEstatePro, the pie chart will not be displayed. Labels of the Statistics window will still display). 3. Open Statistics window by key diff --git a/docs/UserGuide.md b/docs/UserGuide.md index a0d2eb4527a..94f45641c3e 100644 --- a/docs/UserGuide.md +++ b/docs/UserGuide.md @@ -22,7 +22,7 @@ Original AB3 User Guide: [link](https://se-education.org/addressbook-level3/User - [Adding a client: `add`](#adding-a-client-add) - [Editing a client: `edit`](#editing-a-client-edit) - [Deleting a client: `delete`](#deleting-a-client-delete) - - [Favourite a client: `favourite`](#favourite-a-client-favourite) + - [Favourite a client: `favourite`](#favourite-or-unfavourite-a-client-favourite) - [Open Favourites window: `fw`](#open-favourites-window-fw) - [Finding clients by keyword: `find`](#finding-clients-by-keyword-find) - [Sorting clients: `sort`](#sorting-clients-sort) @@ -223,9 +223,12 @@ Examples: **Note**: - Images associated with the client are not deleted and remains in the OS file system. -### Favourite a client: `favourite` +### Favourite or Unfavourite a client: `favourite` -Favourites the specified client in the RealEstatePro represented by a star as shown below. + Favourites the specified client in the RealEstatePro represented by a star as shown below. + +💡 **Note**: + * If the client was favourited before, calling `favourite` command on this particular client will unfavourite him/her. This command will remove "🌟" from the client.
Additionally, the client information will not show up on the Favourites window anymore. The user (real estate agent) will be able to view a more compact list of favourited clients in a new window called Favourites window. @@ -233,7 +236,7 @@ The user (real estate agent) will be able to view a more compact list of favouri Format: `favourite INDEX` -- Favourites the client at the specified `INDEX`. +- Favourites/unfavourites 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, … @@ -251,7 +254,12 @@ Format:  `fw` 2) Under it, click on `Favourites`. -3) The system will pop up the Favourites window that displays the compacted list of clients that have been favourited. +3) The system will pop up the Favourites window. + +#### By Key: `F3` + +1) Press `F3`. +2) The system will pop up the Favourites window. ![images/user-guide/openFavouriteWindow.png](images/user-guide/openFavouriteWindow.png) @@ -428,6 +436,22 @@ Opens up a new window that shows a pie chart of the number of buyers & sellers w Format: `stats` +#### By Ui: + +1) Navigate to the `File` menu and click on it. + +2) Under it, click on `Stats`. + +3) The system will pop up the Statistics window. + +#### By Key: `F2` + +1) Press `F2`. + +2) The system will pop up the Statistics window. + + +