Skip to content

Commit

Permalink
Merge pull request nus-cs2103-AY1819S2#68 from JiaHaoLim/update-docum…
Browse files Browse the repository at this point in the history
…entation

Updated UserGuide.adoc
  • Loading branch information
kthSim authored Mar 15, 2019
2 parents e6948e7 + e47bfdd commit 21a532a
Showing 1 changed file with 64 additions and 9 deletions.
73 changes: 64 additions & 9 deletions docs/UserGuide.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -346,24 +346,79 @@ newly created teeth layout.
indicate personalised note describing more detail on the patient’s teeth
health.

=== Importing records: `import`
=== Open
Opens the file in the specified file path and overwrites the current records.
** Note that 'open' always searches inside the data folder.

Reads all entries from a specified text file and overwrites the address book. +
Format: `import FILENAME`
Format: `open FILE_PATH`

Examples:

* `import records1.json` +
Reads all entries from a records1.json and overwrites the address book. +
* `open records1.json` +
Replaces the current records with the records in "records1.json".

=== Exporting records: `export`
* `open february\records2.json` +
Replaces the current records with the records in "records2.json" found in the "february" folder.

Writes all entries from the address book to a specified text file. +
If no file exists, a new one will be created.
Format: `export FILENAME`

=== Save
Saves the current records to the specified filepath.
** Note that 'save' always saves inside the data folder. If no such filepath exists,
it will be created. Otherwise, it will overwrite the existing file.

Format: `save FILE_PATH`

Examples:

* `save records1.json` +
Saves the current records to "records1.json".

* `save february\records2.json` +
Saves the current records to "records1.json" found in the "february" folder.


=== Import
Opens the file in the specified file path and adds the specified patients to the current records.
** Note that 'import' always searches inside the data folder.

Format: `import FILE_PATH INDEX_RANGE`

Examples:

* `import records1.json 1` +
Adds patient 1 from "records1.json" to the current records.

* `import february\records1.json 1` +
Adds patient 1 from "records1.json" found in the "february" folder to the current records.

* `import records1.json 1,4` +
Adds patient 1 and patient 4 from "records1.json" to the current records.

* `import records1.json 1-4` +
Adds patient 1 to patient 4 from "records1.json" to the current records.


=== Export
Saves the specified patients in the current records to the specified filepath.
** Note that 'export' always saves inside the data folder. If no such filepath exists,
it will be created. Otherwise, it will overwrite the existing file.

Format: `export FILE_PATH INDEX_RANGE`

Examples:

* `export records1.json 1` +
Saves patient 1 from the current records to "records1.json".

* `export february\records1.json 1` +
Saves patient 1 from the current records to "records1.json" found in the "february" folder.

* `export records1.json 1,4` +
Saves patient 1 and patient 4 from the current records to "records1.json".

* `export records1.json 1-4` +
Saves patient 1 to patient 4 from the current records to "records1.json".

* `Export records2.json` +
Writes all entries from the address book to records2.json. +

Expand Down

0 comments on commit 21a532a

Please sign in to comment.