Skip to content

Commit

Permalink
Merge pull request #301 from uberSaiyan/fix-docs
Browse files Browse the repository at this point in the history
Fix ug and ppp
  • Loading branch information
EugeneTeu committed Nov 11, 2019
2 parents 010cf04 + eaebb17 commit 2661410
Show file tree
Hide file tree
Showing 5 changed files with 32 additions and 37 deletions.
4 changes: 2 additions & 2 deletions docs/AboutUs.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ In Charge of: Storage
image::zhixianggg.png[width="150", align="left"]
{empty}[https://github.com/zhixianggg[github]][<<zhixianggg#, portfolio>>]

Role: Code Quality, Logic
Role: Code Quality

In Charge of: Parsing + CRUD
In Charge of: Undo/Redo Commands, CRUD Commands and Logic

'''

Expand Down
20 changes: 10 additions & 10 deletions docs/DeveloperGuide.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ The sections below give more details of each component.
=== UI component
// tag::UiUG[]
.Structure of the UI Component
image::UiClassDiagram.png[width="400"]
image::UiClassDiagram.png[]

*API*: link:{repoURL}/src/main/java/seedu/address/ui/Ui.java[`Ui.java`]

Expand Down Expand Up @@ -284,7 +284,7 @@ single object, passed it to the appropriate place to be "unwrapped" when needed.

A high-level view of the packages working together:

image::statsOverallClassDiagram.png[width="300", align="center"]
image::statsOverallClassDiagram.png[align="center"]

==== Current Implementation

Expand All @@ -305,19 +305,19 @@ the `statsCommandParser` parses the input from the user, returning a

Seen here is the sequence diagram of the first step

image::StatsCommandSequenceDiagram1.png[width="400", align="center"]
image::StatsCommandSequenceDiagram1.png[align="center"]

Step 2: the logic then calls `command.execute(command)`.

When this happens, the `StatsCommand` executes, which triggers a call to create a new `StatsPayload`. Then this is used to
create a new `CommandResult` object and returns that to `Logic`, completing the execution of the user input command.
Seen here is the sequence diagram of the second step.

image::StatsCommandSequenceDiagram2.png[width="400", align="center"]
image::StatsCommandSequenceDiagram2.png[align="center"]

Shown below is a quick summary of step 1-2 (Full complete diagram):

image::StatsCommandSequenceDiagram.png[width="600", align="center"]
image::StatsCommandSequenceDiagram.png[align="center"]

Step 3: After the logic component completes its execution and return a `CommandResult`, the `UI` will call
`performUiChanges` that handles the specific `UI` change. This then results in the `statsPayload` class being
Expand All @@ -333,14 +333,14 @@ a `String` or a `XYChart.Series<String, Number>`.
Step 5: with this output from logic, `Statistic Window` will then handle the displaying of the statistic, be it in chart
form or string form. With this, the feature has finished executing! Attached below is the summary for step 3-5:

image::StatisticsCalculationUI.png[width="400", align="center"]
image::StatisticsCalculationUI.png[align="center"]


==== Current Version `v1.4`:

Here is a screenshot of the current product:

image::StatsExampleGraph.png[width="300" align="center"]]
image::StatsExampleGraph.png[align="center"]]


==== Limitations/Note to developers:
Expand Down Expand Up @@ -459,7 +459,9 @@ from `AutoCompleteValueProvider` in the form of `AutoCompleteNode`.
For clarity, here are some class diagrams for the AutoComplete package.

image::AutoCompleteClassDiagram.png[]

image::GraphsClassDiagram.png[]

image::NodesClassDiagram.png[]

===== Alternative Designs
Expand Down Expand Up @@ -677,7 +679,7 @@ and `saveArchivedOrderBookSnapshot(Model model)` will be called. This ensures th
After a command is executed, `LogicManager` will add it into the `UndoRedoStack`.
This will be explained in the activity diagram below.

image::dg-diagram/UndoRedoStackPushActivityDiagram.png[width="600"]
image::dg-diagram/UndoRedoStackPushActivityDiagram.png[width="800"]

Next, when `UndoCommand` is being performed, `UndoStack` will remove the first command in its stack and add it to `RedoStack`.
It will then call `UndoableCommand#undo()` of the command that is removed.
Expand Down Expand Up @@ -1150,8 +1152,6 @@ These instructions only provide a starting point for testers to work on; testers
.. If file "a" has dependency on file "b", and file "a" is missing, both empty file "a" and "b" will be loaded.
.. If file is corrupted i.e. wrong string input, sample file will be loaded.

_{ more test cases ... }_

// end::savingData[]

=== Testing Statistics
Expand Down
42 changes: 20 additions & 22 deletions docs/UserGuide.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ toggle to the Tab Panel that it belongs to.
====
*Command Format*
* Words in `UPPER_CASE` are the parameters to be supplied by the user e.g. in `add -c n/NAME`, `NAME` is a parameter which can be used as `add -c n/John Doe`.
* Words in `UPPER_CASE` are the parameters to be supplied by the user e.g. in `add-c n/NAME`, `NAME` is a parameter which can be used as `add-c 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 `{nbsp}` (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/CONTACT_NUMBER`, `c/CONTACT_NUMBER n/NAME` is also acceptable.
Expand Down Expand Up @@ -360,15 +360,17 @@ Switches to Phone Tab Panel.
==== Add a phone: `add-p`
Adds a phone. Similar to adding a customer. +

[underline]#Format#: `add-p i/IDENTITY NUMBER (IMEI) s/SERIAL NUMBER n/NAME b/BRAND cp/CAPACITY (in GB) cl/COLOUR $/COST [t/TAG]…​`
[underline]#Format#: `add-p i/IDENTITY_NUMBER s/SERIAL_NUMBER n/NAME b/BRAND cp/CAPACITY (in GB) cl/COLOUR $/COST [t/TAG]…​`

[TIP]
IMEI Number should be 15 digits long.
Identity Number (IMEI) should be 15 digits long.
[TIP]
Capacity can be 8GB, 16GB, 32GB, 64GB, 128GB, 256GB, 512GB or 1024GB. You do not need to type GB after the prefix cp/.
[TIP]
Cost must start with $ and can only have a maximum of 2 decimal place.
[TIP]
The maximum cost allowed is $999999999.99.
[TIP]
A customer can have any number of tags, including 0.

[underline]#Examples#:
Expand Down Expand Up @@ -442,7 +444,7 @@ Clears every phone in SML. +

==== Edit a phone: `edit-p`
Edits the data fields of a phone. Note that orders in the order tab panel associated with the phone will also be edited. +
[underline]#Format#: `edit-p INDEX [i/IMEI] [s/SERIAL NUMBER] [n/NAME] [b/BRAND] [cp/CAPACITY] [cl/COLOUR] [$/COST] [t/TAG]…`
[underline]#Format#: `edit-p INDEX [i/IDENTITY_NUMBER] [s/SERIAL_NUMBER] [n/NAME] [b/BRAND] [cp/CAPACITY] [cl/COLOUR] [$/COST] [t/TAG]…`


****
Expand Down Expand Up @@ -504,9 +506,7 @@ Format: `add-o c/CUSTOMER_INDEX p/PHONE_INDEX $/PRICE [t/TAG]...`
****
* Negative prices will be rejected.
* $0 is accepted to accommodate for free transactions.
* Prices above 1.7 * 10^308^ will not be rejected. However, they will
*corrupt* the data. There is no practical reason
for a price to be that high.
* The maximum price allowed is $999999999.99.
****

==== Find an order: `find-o`
Expand Down Expand Up @@ -798,7 +798,6 @@ Currently, the following commands are undoable and redoable. +

[underline]#Examples#:

// tag::statisticsCommand[]
* Redo clear Customer Book
. `clear-c`
. `undo`
Expand Down Expand Up @@ -828,9 +827,6 @@ Exits the program. +

If there are any statistics window open when executing this, the application will not terminate until those windows are closed too.


// tag::statisticsCommand[]

// tag::statisticsCommandUG[]
=== Generate stats: `generate-s`

Expand Down Expand Up @@ -863,18 +859,16 @@ The argument must match these three words perfectly.

Shown below:


image::StatsExampleDefault.png[width="300"]


Generates the statistics with date input in chart format (in pop-up modal dialogue). +
Format: `generate-s s/stat d1/YYYY.MM.DD d2/YYYY.MM.DD` +
Example: `generate-s s/revenue d1/2019.10.16 d2/2019.11.21` +
Format for the date is in YYYY.MM.DD e.g `2019.05.12`

Shown below:

image::StatsExampleGraph.png[width="300"]
image::StatsExampleGraph.png[]

// end::statisticsCommandUG[]
[TIP]
Expand Down Expand Up @@ -966,7 +960,7 @@ The system may lag and not work if you are typing too fast.
[TIP]
The system is case-sensitive.

==== Example: `add`
==== `add`

image::AutoCompleteAddExample.png[]

Expand Down Expand Up @@ -996,7 +990,7 @@ confusion.
accordingly.
****

==== Example: `delete-c`
==== `delete`

image::AutoCompleteDeleteExample.png[]

Expand All @@ -1009,7 +1003,7 @@ where `N` is the largest valid index that can be entered. In this case,
* Commands of this type include `delete`, `copy`, `complete`, `cancel`.
****

==== Example: `edit`
==== `edit`

*** When you enter `edit-c` followed by a space, the system will suggest
two numbers: `1` and `N`, where `N` is the largest valid index that can
Expand All @@ -1033,7 +1027,7 @@ the system is designed to always suggest the entire set of possible prefixes.
* Autocomplete works similarly for all `edit` commands.
****

==== Example: `find`
==== `find`

image::AutoCompleteFindExample.png[]

Expand All @@ -1049,7 +1043,7 @@ entered.
****


==== Example: `switch`
==== `switch`

*** For simple commands such as `switch-c`, the system will suggest the command word
and nothing else.
Expand All @@ -1058,7 +1052,7 @@ and nothing else.
* Simple commands include `switch`, `export`, `list`, `clear`, `undo`, `redo`, `history`, `exit`, `help`.
****

==== Example: `schedule`
==== `schedule`

image::AutoCompleteScheduleExample.png[]

Expand Down Expand Up @@ -1134,6 +1128,8 @@ The hashtag represents the length of the valid input for the primary key.

[underline]#Format#: `addfield PRODUCT_NAME FIELD_NAME DATA_TYPE`

// tag::autocomplete[]

==== Autocomplete integrated with command history `[coming in v2.0]`

This extension of the autocomplete feature is to allow users to receive
Expand All @@ -1145,6 +1141,8 @@ This feature is to allow users to define customized command words to
simplify long commands. For example, `generate-s s/profit` can be
simplified to `gp`.

// end::autocomplete[]

== FAQ
*Q*: How do I transfer my data to another Computer? +
*A*: Install the app in the other computer and overwrite the empty data file it creates with the file that contains the data of your previous SML folder.
Expand Down Expand Up @@ -1173,8 +1171,8 @@ simplified to `gp`.
[width="100%",cols="20%,<30%",options="header",]
|=======================================================================
|Command | Summary
|`add-p i/IDENTITY NUMBER (IMEI) s/SERIAL NUMBER n/NAME b/BRAND cp/CAPACITY (in GB) cl/COLOUR $/COST [t/TAG]…​`| Adds a new phone into SML.
|`edit-p INDEX [i/IMEI] [s/SERIAL NUMBER] [n/NAME] [b/BRAND] [cp/CAPACITY] [cl/COLOUR] [$/COST] [t/TAG]…`| Edits an existing phone.
|`add-p i/IDENTITY_NUMBER s/SERIAL_NUMBER n/NAME b/BRAND cp/CAPACITY (in GB) cl/COLOUR $/COST [t/TAG]…​`| Adds a new phone into SML.
|`edit-p INDEX [i/IDENTITY_NUMBER] [s/SERIAL_NUMBER] [n/NAME] [b/BRAND] [cp/CAPACITY] [cl/COLOUR] [$/COST] [t/TAG]…`| Edits an existing phone.
|`delete-p INDEX`| Deletes a phone and its associated orders and schedules.
|`clear-p`| Deletes all phones and their associated orders and schedules.
|`find-p KEYWORD [MORE_KEYWORDS]`| Finds the phones that contain the keywords in its field.
Expand Down
Binary file modified docs/images/AutoCompleteClassDiagram.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 0 additions & 3 deletions docs/templates/_header.html.slim
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,6 @@
=nav_link('UserGuide', 'UserGuide.html', 'User Guide')
li.nav-item
=nav_link('DeveloperGuide', 'DeveloperGuide.html', 'Developer Guide')
- if attr? 'site-seedu'
li.nav-item
=nav_link('LearningOutcomes', 'LearningOutcomes.html', 'LOs')
li.nav-item
=nav_link('AboutUs', 'AboutUs.html', 'About Us')
li.nav-item
Expand Down

0 comments on commit 2661410

Please sign in to comment.