From 6dcb282632743ab5151a37a983e43d69487c5a13 Mon Sep 17 00:00:00 2001 From: WEN SHUFA Date: Thu, 31 Oct 2019 21:37:07 +0800 Subject: [PATCH 1/3] updates CliSyntax class --- docs/UserGuide.adoc | 80 +++++++++++++++++++++++---------------------- 1 file changed, 41 insertions(+), 39 deletions(-) diff --git a/docs/UserGuide.adoc b/docs/UserGuide.adoc index fb977731f20..2f7e009faae 100644 --- a/docs/UserGuide.adoc +++ b/docs/UserGuide.adoc @@ -39,7 +39,7 @@ e.g. typing *`help`* and pressing kbd:[Enter] will open the help window. Alterna . Some example commands you can try: -* `register i/001A n/John Doe p/98765432 e/johnd@example.com a/John street, block 123, #01-01` : registers a patient named `John Doe`. +* `register -id 001A -name John Doe -phone 98765432 -email johnd@example.com -address John street, block 123, #01-01` : registers a patient named `John Doe`. * `enqueue 001A` : enqueues patient with reference id `001A` into the queue. * *`exit`* : exits the app. @@ -60,10 +60,10 @@ e.g. typing *`help`* and pressing kbd:[Enter] will open the help window. Alterna ==== *Command Format* -* Words in `` are the parameters to be supplied by the user e.g. in `register n/NAME`, `NAME` is a parameter which can be used as `register 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/ p/`, `p/ n/` is also acceptable. +* Words in `` are the parameters to be supplied by the user e.g. in `register -name NAME`, `NAME` is a parameter which can be used as `register -name John Doe`. +* Items in square brackets are optional e.g `-name NAME [-tag TAG]` can be used as `-name John Doe -tag friend` or as `-name John Doe`. +* Items with `…`​ after them can be used multiple times including zero times e.g. `[-tag TAG]...` can be used as `{nbsp}` (i.e. 0 times), `-tag friend`, `-tag friend -tag family` etc. +* Parameters can be in any order e.g. if the command specifies `-name -phone `, `-phone -name ` is also acceptable. ==== @@ -107,14 +107,14 @@ Format: `patient []` ==== Registers a new patient: `register` ==== Registers a new patient. + -Format: `register i/ n/ [p/] - [e/] [a/
] [r/] [t/Allergies]...` +Format: `register -id -name [-phone ] + [-email ] [-address
] [r/] [-tag Allergies]...` ==== Updates patients’ profiles: `update` ==== If user is in the patients listing screen, updates any change for patients’ profiles + -Format: `update [n/] [i/] [p/] - [e/] [a/
] [r/] [t/Allergies]...` +Format: `update [-name ] [-id ] [-phone ] + [-email ] [-address
] [r/] [-tag Allergies]...` === On-Duty Doctors Management === @@ -129,13 +129,13 @@ Format: `doctors []` Registers a new doctor. + If the staff reference identifier is not specified, a unique identifier will be assigned by the system. -Format: `newdoctor n/ [i/] [p/] [e/] [a/
] [r/]` +Format: `newdoctor -name [-id ] [-phone ] [-email ] [-address
] [r/]` ==== Updates a doctor's profile: `updatedoctor` ==== If user is in the doctors listing screen, updates any change for doctor’s profiles. + -Format: `updatedoctor [n/] -[i/] [p/] [e/] [a/
] [r/]` +Format: `updatedoctor [-name ] +[-id ] [-phone ] [-email ] [-address
] [r/]` ==== Marks the doctor as on-duty: `onduty` ==== @@ -152,37 +152,36 @@ Format: `offduty ` ==== Adds an appointment: `addappt` ==== Adds a new appointment for a patient + -If no optional fields `[rec/REPEATEDLY]` and `[num/RECURSIVE_TIMES]` are present, only one event will be added. Otherwise repeated appointments will be added. + -The field `rec/REPEATEDLY` can be `rec/w`, `rec/m`, or `rec/y`.They represent to add weekly, monthly, yearly repeat appointment respectively. -Format: `addappt [i/REFERENCE_ID] str/ [rec/REPEATEDLY] [num/REPEATED_TIMES]` +If no optional fields `[-rec REPEATEDLY]` and `[-num RECURSIVE_TIMES]` are present, only one event will be added. Otherwise repeated appointments will be added. + -Examples: +If no optional fields `[-end ]` is present, default endTiming is 30 mins after startTiming. Otherwise endTiming will be `[-end ]`. + -* `addappt i/001A str/01/12/19 0900` -* `addappt i/001A str/02/12/19 0900 rec/m num/2` +The field `-rec REPEATEDLY` can be `-rec w`, `-rec m`, or `-rec y`.They represent to add weekly, monthly, yearly repeat appointment respectively. + +Format: `addappt -id -start [-end ] [-rec REPEATEDLY] [-num REPEATED_TIMES]` ==== Acknowledges a appointment: `ackappt` ==== Acknowledges an existing appointment once the patient has arrived + -Format: `ackappt [i/REFERENCE_ID]` +Format: `ackappt -id ` ==== Displays all appointments: `appointments` ==== -Displays a sorted list of upcoming appointments for the patient that is associated to the given `i/REFERENCE_ID` + +Displays a sorted list of upcoming appointments for the patient that is associated to the given `-id REFERENCE_ID` + If no keywords are given, all upcoming appointments will be displayed. + -Format: `appointments [i/REFERENCE_ID]` +Format: `appointments [-id ]` ==== Cancels an appointment: `cancelappt` ==== - Cancels the specified appointment. + Format: `cancelappt ` ==== Changes the appointment date: `changeappt` ==== Changes the timing for an existing appointment. + -Format: `changeappt [str/]` +If no optional fields `[-end ]` is present, default endTiming is 30 mins after startTiming. Otherwise new endTiming will be `[-end ]`. + +Format: `changeappt -start [-end ]` ==== Displays patients who have missed their appointments: `missappt` ==== @@ -202,14 +201,14 @@ Format: `maxconcurrentappt ` ==== Shows the empty slots: `slot` (v2.0) ==== List all the available empty slots for patients to make appointments + -Format: `slot str/` +Format: `slot -start ` === Duty-shift Management ==== Adds a duty shift for a doctor: `addshift` ==== Adds a new duty shift for a doctor. + -Format: `addshift [i/STAFF_REFERENCE_ID] str/ [rec/REPEATEDLY] [num/REPEATED_TIMES]` +Format: `addshift [-id STAFF_REFERENCE_ID] -start -end [-rec REPEATEDLY] [-num REPEATED_TIMES]` ==== Cancels a duty shift for a doctor: `cancelshift` ==== @@ -219,7 +218,10 @@ Format: `cancelshift ` ==== Changes the duty shift for a doctor: `changeshift` ==== Changes the timing of an existing duty shift based on the given entry index. + -Format: `changeshift [str/]` + +If no optional fields `[-rec REPEATEDLY]` and `[-num RECURSIVE_TIMES]` are present, only one event will be added. Otherwise repeated appointments will be added. + + +Format: `changeshift -start -end ` === Inventory Commands (v2.0) === @@ -278,34 +280,34 @@ Format: `redo` * *Patient Management* + ** patient: `patient []` -** register: `register i/ n/ [p/] - [e/] [a/
] [r/] [t/Allergies]...` +** register: `register -id -name [-phone ] + [-email ] [-address
] [r/] [-tag Allergies]...` ** unregister: `unregister ` -** update: `update [n/] [i/] [p/] - [e/] [a/
] [r/] [t/Allergies]...` +** update: `update [-name ] [-id ] [-phone ] + [-email ] [-address
] [r/] [-tag Allergies]...` * *On-Duty Doctors Management* + ** doctors: `doctors []` -** newdoctor: `newdoctor n/ [i/] [p/] [e/] [a/
] [r/]` -** updatedoctor: `updatedoctor [n/] -[i/] [p/] [e/] [a/
] [r/]` +** newdoctor: `newdoctor -name [-id ] [-phone ] [-email ] [-address
] [r/]` +** updatedoctor: `updatedoctor [-name ] +[-id ] [-phone ] [-email ] [-address
] [r/]` ** resigndoctor: `resigndoctor ` ** onduty: `onduty ` ** offduty: `offduty ` * *Appointment Management* + -** addappt: `appointments [p/] [rec/REPEATEDLY] [num/TIMES]` -** ackappt: `appointments [p/]` -** appointments: `appointments [p/]` +** addappt: `appointments [-phone ] [-rec REPEATEDLY] [-num TIMES]` +** ackappt: `appointments [-phone ]` +** appointments: `appointments [-phone ]` ** cancelappt: `cancelappt ` -** changeappt: `changeappt [str/]` +** changeappt: `changeappt [-start ]` ** missappt: `missappt` ** settle: `settle ` * *Duty-shift Management* + -** addshift: `addshift [i/STAFF_REFERENCE_ID] str/ [rec/REPEATEDLY] [num/REPEATED_TIMES]` +** addshift: `addshift [-id STAFF_REFERENCE_ID] -start [-rec REPEATEDLY] [-num REPEATED_TIMES]` ** cancelshift: `cancelshift ` -** changeshift: `changeshift [str/]` +** changeshift: `changeshift [-start ]` * *Inventory commands (v2.0)* + ** inventory: `inventory` From 61b53b254ce73257e4d68d27970b9d6d01b5368f Mon Sep 17 00:00:00 2001 From: WEN SHUFA Date: Thu, 31 Oct 2019 21:41:18 +0800 Subject: [PATCH 2/3] removes all "remarks" --- docs/UserGuide.adoc | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/docs/UserGuide.adoc b/docs/UserGuide.adoc index 2f7e009faae..7f6acd88390 100644 --- a/docs/UserGuide.adoc +++ b/docs/UserGuide.adoc @@ -108,13 +108,13 @@ Format: `patient []` Registers a new patient. + Format: `register -id -name [-phone ] - [-email ] [-address
] [r/] [-tag Allergies]...` + [-email ] [-address
] -num [-tag Allergies]...` ==== Updates patients’ profiles: `update` ==== If user is in the patients listing screen, updates any change for patients’ profiles + Format: `update [-name ] [-id ] [-phone ] - [-email ] [-address
] [r/] [-tag Allergies]...` + [-email ] [-address
] -num [-tag Allergies]...` === On-Duty Doctors Management === @@ -129,13 +129,13 @@ Format: `doctors []` Registers a new doctor. + If the staff reference identifier is not specified, a unique identifier will be assigned by the system. -Format: `newdoctor -name [-id ] [-phone ] [-email ] [-address
] [r/]` +Format: `newdoctor -name [-id ] [-phone ] [-email ] [-address
]-num ` ==== Updates a doctor's profile: `updatedoctor` ==== If user is in the doctors listing screen, updates any change for doctor’s profiles. + Format: `updatedoctor [-name ] -[-id ] [-phone ] [-email ] [-address
] [r/]` +[-id ] [-phone ] [-email ] [-address
]-num ` ==== Marks the doctor as on-duty: `onduty` ==== @@ -281,16 +281,16 @@ Format: `redo` * *Patient Management* + ** patient: `patient []` ** register: `register -id -name [-phone ] - [-email ] [-address
] [r/] [-tag Allergies]...` + [-email ] [-address
] -num [-tag Allergies]...` ** unregister: `unregister ` ** update: `update [-name ] [-id ] [-phone ] - [-email ] [-address
] [r/] [-tag Allergies]...` + [-email ] [-address
] -num [-tag Allergies]...` * *On-Duty Doctors Management* + ** doctors: `doctors []` -** newdoctor: `newdoctor -name [-id ] [-phone ] [-email ] [-address
] [r/]` +** newdoctor: `newdoctor -name [-id ] [-phone ] [-email ] [-address
]-num ` ** updatedoctor: `updatedoctor [-name ] -[-id ] [-phone ] [-email ] [-address
] [r/]` +[-id ] [-phone ] [-email ] [-address
]-num ` ** resigndoctor: `resigndoctor ` ** onduty: `onduty ` ** offduty: `offduty ` From bdf141b7c68a2567bcf0be6a75f7777bd402b19b Mon Sep 17 00:00:00 2001 From: WEN SHUFA Date: Thu, 31 Oct 2019 21:52:25 +0800 Subject: [PATCH 3/3] removes extra space --- docs/UserGuide.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/UserGuide.adoc b/docs/UserGuide.adoc index 7f6acd88390..cbea77f6b43 100644 --- a/docs/UserGuide.adoc +++ b/docs/UserGuide.adoc @@ -107,7 +107,7 @@ Format: `patient []` ==== Registers a new patient: `register` ==== Registers a new patient. + -Format: `register -id -name [-phone ] +Format: `register -id -name [-phone ] [-email ] [-address
] -num [-tag Allergies]...` ==== Updates patients’ profiles: `update` ==== @@ -280,7 +280,7 @@ Format: `redo` * *Patient Management* + ** patient: `patient []` -** register: `register -id -name [-phone ] +** register: `register -id -name [-phone ] [-email ] [-address
] -num [-tag Allergies]...` ** unregister: `unregister ` ** update: `update [-name ] [-id ] [-phone ]