Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CS2113-F10-3] TARBS #26

Open
wants to merge 200 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
200 commits
Select commit Hold shift + click to select a range
5c616f8
Set theme jekyll-theme-minimal
Mar 4, 2022
80c25f7
Update AboutUs.md
Mar 4, 2022
6035a3d
update AboutUs
chintaiann Mar 4, 2022
4fda6aa
Add brendan to aboutus
bbawj Mar 4, 2022
e8f9de0
Merge branch 'master' into taiann-AboutUs
chintaiann Mar 4, 2022
8407b47
Merge pull request #1 from chintaiann/taiann-AboutUs
chintaiann Mar 4, 2022
d40c81f
update about-us
timchang27 Mar 4, 2022
cd544ae
Merge branch 'master' into master
bbawj Mar 4, 2022
06dd055
Merge pull request #2 from bbawj/master
bbawj Mar 4, 2022
354e627
v1.0
chintaiann Mar 10, 2022
d41ab0e
Merge pull request #4 from chintaiann/master
chintaiann Mar 10, 2022
8c7ce9b
Add OOP abstractions
bbawj Mar 10, 2022
b4799bf
Merge pull request #5 from bbawj/master
bbawj Mar 10, 2022
5628838
v1.0 - Some bugs
timchang27 Mar 11, 2022
146fd7c
v1.0 - Some bugs
timchang27 Mar 11, 2022
9142291
v1.0 - Some bugs
timchang27 Mar 11, 2022
aa628d0
v1.0 - Some bugs
timchang27 Mar 11, 2022
66bf249
v1.0
chintaiann Mar 17, 2022
20ecd8b
Merge pull request #6 from chintaiann/master
chintaiann Mar 17, 2022
ba42c73
make general revision
Mar 17, 2022
40314b7
revise the style
Mar 17, 2022
5932e94
revise the style
Mar 17, 2022
4b66d08
Merge pull request #7 from edemirkirkan/master
Mar 17, 2022
2b759a9
Added storage
mafpovbul Mar 24, 2022
b9fc095
Merge branch 'master' of https://github.com/AY2122S2-CS2113-F10-3/tp
timchang27 Mar 24, 2022
212b268
v1.0 - Initial Changes
timchang27 Mar 24, 2022
2948ac2
Added the 'help' command
Mar 24, 2022
add2be9
Revise the import issue
Mar 24, 2022
d809612
Merge pull request #10 from edemirkirkan/master
Mar 24, 2022
9b7ebe6
Update DeveloperGuide.md
timchang27 Mar 24, 2022
64ba090
Merge pull request #8 from mafpovbul/master
mafpovbul Mar 26, 2022
098dc21
Refactored storage, added more exception handling
mafpovbul Mar 26, 2022
3006887
changed save file
mafpovbul Mar 26, 2022
6f15baa
Merge branch 'master' into master
mafpovbul Mar 26, 2022
a73a44c
Update DeveloperGuide.md
mafpovbul Mar 26, 2022
122fc40
Merge pull request #11 from mafpovbul/master
mafpovbul Mar 27, 2022
03f2e88
Add files via upload
mafpovbul Mar 27, 2022
d01889c
Update DeveloperGuide.md
mafpovbul Mar 27, 2022
4c85f6b
Delete storage sequence diagram.png
mafpovbul Mar 27, 2022
300b235
Add files via upload
mafpovbul Mar 27, 2022
fd4f689
Update DeveloperGuide.md
mafpovbul Mar 27, 2022
acdd0fb
Update DeveloperGuide.md
mafpovbul Mar 27, 2022
d6f852f
Update DeveloperGuide.md
mafpovbul Mar 27, 2022
9654fc6
Update UserGuide.md
mafpovbul Mar 27, 2022
6aa0c39
Update UserGuide.md
mafpovbul Mar 27, 2022
54f4643
Abstract reservations out from packages
bbawj Mar 27, 2022
bc3456c
Merge pull request #12 from bbawj/master
bbawj Mar 27, 2022
66c0907
Update DeveloperGuide.md
bbawj Mar 27, 2022
e449f68
Add ParserTest
bbawj Mar 27, 2022
87c824f
Merge pull request #13 from bbawj/master
bbawj Mar 27, 2022
20ee0ca
Update to TARBS
bbawj Mar 27, 2022
175cf40
Merge pull request #14 from bbawj/master
bbawj Mar 27, 2022
2b93114
Update DeveloperGuide.md
mafpovbul Mar 27, 2022
b6b12f9
Delete StorageSeqDiag.png
mafpovbul Mar 27, 2022
297d751
Add files via upload
mafpovbul Mar 27, 2022
b371ad8
Delete StorageSeqDiag.png
mafpovbul Mar 27, 2022
c6b416a
Add files via upload
mafpovbul Mar 27, 2022
a75449a
Update to TARBS
bbawj Mar 27, 2022
77b29ee
Merge pull request #15 from bbawj/master
bbawj Mar 27, 2022
1f74e31
Update DeveloperGuide.md
bbawj Mar 27, 2022
9077526
Merge branch 'master' into master
timchang27 Mar 27, 2022
de7169f
Merge pull request #9 from timchang27/master
timchang27 Mar 27, 2022
d123fc4
v2.0
chintaiann Mar 29, 2022
9cd44c1
Merge pull request #16 from chintaiann/master
chintaiann Mar 29, 2022
85419f6
Add exception handling and print reservations
bbawj Mar 30, 2022
42bcaef
Merge pull request #17 from bbawj/master
bbawj Mar 30, 2022
24aea0c
Add override equals for testing
bbawj Mar 31, 2022
f9486b4
Merge pull request #18 from bbawj/master
bbawj Mar 31, 2022
6e0658c
Update DeveloperGuide.md
mafpovbul Mar 31, 2022
86fc569
Add files via upload
mafpovbul Mar 31, 2022
5770959
Update DeveloperGuide.md
mafpovbul Mar 31, 2022
24cd456
v2.0
chintaiann Mar 31, 2022
00eaf19
Merge pull request #19 from chintaiann/master
chintaiann Mar 31, 2022
b8da5d6
Update DeveloperGuide.md
chintaiann Mar 31, 2022
c58d435
Update DeveloperGuide.md
chintaiann Mar 31, 2022
dcabde9
Update storage
mafpovbul Mar 31, 2022
b813516
Merge pull request #20 from mafpovbul/master
mafpovbul Mar 31, 2022
3f89b4e
Update TARBS.java
mafpovbul Mar 31, 2022
8876ca1
Delete SaveFileSeqDiag.png
mafpovbul Mar 31, 2022
da2c5b8
Delete StorageSeqDiag.png
mafpovbul Mar 31, 2022
66050d9
Add files via upload
mafpovbul Mar 31, 2022
bfd3199
Delete SaveFileSeqDiag.png
mafpovbul Mar 31, 2022
cb5c05c
Add files via upload
mafpovbul Mar 31, 2022
8baf8b1
Update DeveloperGuide.md
mafpovbul Mar 31, 2022
15874e3
Add SLAP for parser
bbawj Mar 31, 2022
896c5ea
Merge pull request #21 from bbawj/master
bbawj Mar 31, 2022
8e581cb
Update UserGuide.md
bbawj Mar 31, 2022
00ed778
v2.0 - Edited packages command and added info command
timchang27 Mar 31, 2022
a9c753b
Merge pull request #22 from timchang27/master
timchang27 Mar 31, 2022
340d229
Update DeveloperGuide.md
timchang27 Mar 31, 2022
2c872a5
v2.0 - Edited packages command and added info command
timchang27 Mar 31, 2022
32a3257
Merge pull request #23 from timchang27/master
timchang27 Mar 31, 2022
0020ae1
Exception handling
mafpovbul Apr 1, 2022
708bd52
Merge pull request #24 from mafpovbul/master
mafpovbul Apr 1, 2022
39e9523
Add Date support
bbawj Apr 1, 2022
cb25cf6
Merge pull request #25 from bbawj/master
bbawj Apr 1, 2022
c2dfe9a
Add .jar to gitignore
bbawj Apr 1, 2022
e3b8a37
Exception handling for storage
mafpovbul Apr 1, 2022
37f4bdc
Merge pull request #79 from mafpovbul/master
mafpovbul Apr 1, 2022
5e4da5f
Merge remote-tracking branch 'upstream/master'
bbawj Apr 2, 2022
bab17d8
Update help command, closes #77, closes #73, closes #51
bbawj Apr 2, 2022
6569dea
Merge pull request #80 from bbawj/master
bbawj Apr 2, 2022
eb94f62
Code review closes #26
bbawj Apr 2, 2022
3b1d3d8
Merge pull request #81 from bbawj/master
bbawj Apr 2, 2022
be7cda6
Date exception handling
mafpovbul Apr 2, 2022
40ed8a8
Date exception handling
mafpovbul Apr 2, 2022
608e954
Merge pull request #82 from mafpovbul/master
mafpovbul Apr 2, 2022
a690e3b
Add exception handling and tests, closes #42, closes #69, closes #66
bbawj Apr 2, 2022
7181984
Find package logic, added error messages
mafpovbul Apr 2, 2022
25c7843
Merge pull request #83 from mafpovbul/master
mafpovbul Apr 2, 2022
c0fc452
Fix conflict
bbawj Apr 2, 2022
1aa1306
Merge pull request #84 from bbawj/master
bbawj Apr 2, 2022
728cb32
Error checking when loading storage data
mafpovbul Apr 2, 2022
c3a5171
Merge pull request #85 from mafpovbul/master
mafpovbul Apr 2, 2022
231b364
v2.0 - Removed Unused Command Classes and Deleted Dead Code
timchang27 Apr 2, 2022
74cf9ab
Merge pull request #86 from timchang27/master
timchang27 Apr 2, 2022
4c09fe0
Add storage test code
mafpovbul Apr 2, 2022
f905639
Merge pull request #87 from mafpovbul/master
mafpovbul Apr 2, 2022
733bd63
Add date range test
bbawj Apr 2, 2022
1c40c95
Merge pull request #88 from bbawj/master
bbawj Apr 2, 2022
b6b8dde
small fix
chintaiann Apr 4, 2022
78bfb2e
Merge pull request #89 from chintaiann/master
chintaiann Apr 4, 2022
b60b0ae
Update chintaiann.md
chintaiann Apr 6, 2022
15f00bd
Create justyn.md
mafpovbul Apr 7, 2022
2764c3e
Update justyn.md
mafpovbul Apr 7, 2022
8154180
Add Brendan PPP
bbawj Apr 7, 2022
b1dc964
Merge pull request #90 from bbawj/master
bbawj Apr 7, 2022
a90d94e
Merge pull request #1 from AY2122S2-CS2113-F10-3/master
Apr 7, 2022
ece0522
Fix the same package bug
Apr 7, 2022
9e0ab99
Fix the big integer delete bug
Apr 7, 2022
d7d75b8
Update Project Portfolio Page
timchang27 Apr 7, 2022
ab804e0
Fix exit command documentation bug
Apr 7, 2022
e065dc5
Update user guide and help documentation
Apr 7, 2022
44cce7b
Fix documentation issue
Apr 7, 2022
0a820ca
Update documentation
Apr 7, 2022
142421e
Resolve Issue
timchang27 Apr 7, 2022
10fac69
Merge pull request #91 from timchang27/master
timchang27 Apr 7, 2022
2b954f0
Improved Help and HelpCommand, Corrected Add Instructions
timchang27 Apr 7, 2022
0a94da3
Format Data
timchang27 Apr 7, 2022
724c9cb
Merge pull request #92 from timchang27/master
timchang27 Apr 7, 2022
885c839
Update UserGuide.md
timchang27 Apr 7, 2022
6f3ee1a
Added PPP
timchang27 Apr 7, 2022
17b7f09
Update UserGuide.md
timchang27 Apr 7, 2022
141351b
Merge branch 'master' into master
Apr 8, 2022
5424332
Merge pull request #93 from edemirkirkan/master
Apr 8, 2022
ba84d08
Rename brendan PPP
bbawj Apr 9, 2022
0d5af47
Update justyn.md
mafpovbul Apr 9, 2022
ecd630f
Merge pull request #94 from bbawj/master
bbawj Apr 9, 2022
55e6f2a
Rename justyn.md to mafpovbul.md
mafpovbul Apr 9, 2022
ca39a96
Merge branch 'master' of https://github.com/AY2122S2-CS2113-F10-3/tp
timchang27 Apr 9, 2022
0002a5e
Rename timothy.md to timchang27.md
timchang27 Apr 9, 2022
82791e8
Merge pull request #95 from timchang27/master
timchang27 Apr 9, 2022
57de34d
Added Hotel and Country Class
timchang27 Apr 9, 2022
c04d893
Merge pull request #96 from timchang27/master
timchang27 Apr 9, 2022
ea1ce11
Update timchang27.md
timchang27 Apr 9, 2022
76eb910
Update DeveloperGuide.md
chintaiann Apr 10, 2022
4f0cdcf
Add and View Hotels Command
timchang27 Apr 10, 2022
e46e412
Merge pull request #97 from timchang27/master
timchang27 Apr 10, 2022
98f99e4
Update User Guide
chintaiann Apr 10, 2022
0445a59
Update DeveloperGuide.md
timchang27 Apr 10, 2022
af9f247
Update README.md
chintaiann Apr 10, 2022
67dabef
Update README.md
chintaiann Apr 10, 2022
effd44e
Update README.md
chintaiann Apr 10, 2022
b01ae46
Update Help Command with Hotel related commands
timchang27 Apr 10, 2022
46027b4
Merge pull request #98 from timchang27/master
timchang27 Apr 10, 2022
c9678ea
Update DeveloperGuide.md
chintaiann Apr 10, 2022
c52e37a
implement sort and print package function
chintaiann Apr 10, 2022
e181cf4
Merge branch 'master' of https://github.com/chintaiann/tp
chintaiann Apr 10, 2022
c6477c3
Merge branch 'master' into master
chintaiann Apr 10, 2022
378da6f
Merge pull request #1 from AY2122S2-CS2113-F10-3/master
chintaiann Apr 10, 2022
09fbaac
Merge pull request #99 from chintaiann/master
chintaiann Apr 10, 2022
2c01e2c
Update DeveloperGuide.md
chintaiann Apr 11, 2022
5c5b2ac
Update DeveloperGuide.md
chintaiann Apr 11, 2022
54c8511
Update DeveloperGuide.md
chintaiann Apr 11, 2022
d3c4822
Merge branch 'AY2122S2-CS2113-F10-3:master' into master
chintaiann Apr 11, 2022
25ce741
Update UserGuide.md
chintaiann Apr 11, 2022
9174973
Update data.txt
chintaiann Apr 11, 2022
580c48d
Merge branch 'AY2122S2-CS2113-F10-3:master' into master
chintaiann Apr 11, 2022
da9996a
Merge pull request #100 from chintaiann/master
chintaiann Apr 11, 2022
69994cc
Update chintaiann.md
chintaiann Apr 11, 2022
c87982b
Update AboutUs.md
chintaiann Apr 11, 2022
4835e4c
Update AboutUs.md
timchang27 Apr 11, 2022
7cd5b49
Update AboutUs.md
mafpovbul Apr 11, 2022
a961318
Update AboutUs.md
mafpovbul Apr 11, 2022
dcb082f
Fixed AddHotelCommand
timchang27 Apr 11, 2022
22ab575
Fixed AddHotelCommand
timchang27 Apr 11, 2022
fe73ca9
Merge pull request #101 from timchang27/master
timchang27 Apr 11, 2022
faeab7e
Add portfolio to AboutUs.md
Apr 11, 2022
b0feb67
Merge remote-tracking branch 'origin/master'
Apr 11, 2022
cc1434c
Merge branch 'master' into master
Apr 11, 2022
fb358a7
Update AboutUs.md
Apr 11, 2022
d0a073b
Update AboutUs.md
Apr 11, 2022
231098d
Fixed AddHotelCommand
timchang27 Apr 11, 2022
200d75a
Merge pull request #103 from timchang27/master
timchang27 Apr 11, 2022
db95f13
Update timchang27.md
timchang27 Apr 11, 2022
c6d88d7
Merge branch 'master' into master
Apr 13, 2022
bd890aa
Merge pull request #102 from edemirkirkan/master
Apr 13, 2022
28e8c64
Merge pull request #2 from AY2122S2-CS2113-F10-3/master
Apr 13, 2022
8d02948
Review bug issues
Apr 19, 2022
f5d4f48
Merge pull request #104 from edemirkirkan/master
Apr 19, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,15 @@
/build/
src/main/resources/docs/

*.jar

# MacOS custom attributes files created by Finder
.DS_Store
*.iml
bin/

/text-ui-test/ACTUAL.txt
text-ui-test/EXPECTED-UNIX.TXT

.vscode/
data.txt
3 changes: 3 additions & 0 deletions META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Manifest-Version: 1.0
Main-Class: seedu.duke.TARBS

4 changes: 4 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ repositories {
dependencies {
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-api', version: '5.5.0'
testRuntimeOnly group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.5.0'
testImplementation('org.junit.platform:junit-platform-launcher:1.5.2')
// testImplementation(platform('org.junit:junit-bom:5.8.2'))
// testImplementation('org.junit.jupiter:junit-jupiter')
}

test {
Expand Down Expand Up @@ -43,4 +46,5 @@ checkstyle {

run{
standardInput = System.in
enableAssertions = true
}
4 changes: 4 additions & 0 deletions data.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Experience Seoul | 1 | 01/04/2022 | 08/04/2022 | Marriott Seoul | 100.11 | Korea | 20 | 19$
Conquer Summits | 2 | 05/05/2022 | 11/05/2022 | Hotel Schweizerhof Luzern | 80.0 | Switzerland | 20 | 6$2,Tim,98765432,3%2,Brendan,12345,3%
Back To Our Roots | 3 | 01/04/2022 | 20/04/2022 | Hotel in Malaysia | 50.0 | Malaysia | 100 | 6$3,Tim,98765432,3%3,Brendan,12345,3%
ski | 6 | 29/02/2020 | 19/02/2022 | hotel | 80.0 | country | 30 | 0$
14 changes: 7 additions & 7 deletions docs/AboutUs.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# About us

Display | Name | Github Profile | Portfolio
--------|:----:|:--------------:|:---------:
![](https://via.placeholder.com/100.png?text=Photo) | John Doe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Don Joe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Ron John | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | John Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
![](https://via.placeholder.com/100.png?text=Photo) | Don Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)
| Display | Name | Github Profile | Portfolio |
| --------------------------------------------------- |:---------------:|:-----------------------------------------:| :-------------------------------: |
| ![](https://via.placeholder.com/100.png?text=Photo) | Ege Demirkirkan | [Github](https://github.com/edemirkirkan) | [Portfolio](team/edemirkirkan.md) |
| ![](https://via.placeholder.com/100.png?text=Photo) | Justyn Phoa | [Github](https://github.com/mafpovbul) | [Portfolio](team/mafpovbul.md) |
| ![](https://via.placeholder.com/100.png?text=Photo) | Timothy Chang | [Github](https://github.com/timchang27) | [Portfolio](team/timchang27.md) |
| ![](https://via.placeholder.com/100.png?text=Photo) | Brendan Ang | [Github](https://github.com/bbawj) | [Portfolio](team/bbawj.md) |
| ![](https://via.placeholder.com/100.png?text=Photo) | Chin Tai Ann | [Github](https://github.com/chintaiann) | [Portfolio](team/chintaiann.md) |
115 changes: 104 additions & 11 deletions docs/DeveloperGuide.md
Original file line number Diff line number Diff line change
@@ -1,38 +1,131 @@
# Travel Agency Reservation Booking System (TARBS)
# Developer Guide

## Acknowledgements
## Setting Up

{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}
First, fork this repo, and clone the fork into your computer.

## Design & implementation
You are recommended to use Intellij IDEA to edit the program.

1. Configure the JDK: Ensure Intellij is configured to use JDK 8 or higher.
2. Import the project as a Gradle project: Choose the option to import the project as a Gradle project when prompted.
3. Verify the setup: Enter some commands to ensure TARBS functions as expected.

{Describe the design and implementation of the product. Use UML diagrams and short code snippets where applicable.}
## Design & implementation
### Basic Class Diagram
![image](https://user-images.githubusercontent.com/53790951/160271319-4a351f51-afd7-4e04-9451-f04143146551.png)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think more descriptive roles can be used to describe these relationships, since things like uses or instantiates can already be implied by the arrows? Also, if instantiates implies an association, consider using a solid line for it instead.

image

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Even if the class methods and fields are not represented, there should be another line separating the contents of the class.

Screenshot 2022-03-31 at 11 39 38 AM

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remember to use standard UML syntaxes taught in the module. Some of the notations are not compliant with the notation covered in the module.
Consider adding multiplicity to and other detailed information to the diagram to help understanding.



## Product scope
### Target user profile

{Describe the target user profile}
- Studies in a non-IT field
- Usually works alone
- Working in a small travel agency that offers affordable budget travel packages to only some countries
- Handles many customers a day
- Is unfamiliar with using CLI apps

### Value proposition

{Describe the value proposition: what problem does it solve?}
- Travel agencies often have to manage multiple customers and their respective bookings or plans.
- For employees of the travel agencies to track and record customers’ booking of travel packages.


## User Stories

|Version| As a ... | I want to ... | So that I can ...|
|--------|----------|---------------|------------------|
|v1.0|new user|see usage instructions|refer to them when I forget how to use the application|
|v2.0|user|find a to-do item by name|locate a to-do without having to go through the entire list|
|v1.0|new user|Add reservation for a customer with basic information such as name, country etc. |Make a reservation|
|v1.0|new user|Print a list of all current and available travel packages |View all current travel packages and tell customers about our travel packages with one look|
|v1.0|new user|Remove an existing reservation|Remove information that we do not need anymore|
|v1.0|new user|Search for a specific travel package|Make recommendations to a customer based on their desired travel package requirements|
|v2.0|User ready to start using the app|Upload existing reservation data|Get started quickly|
|v2.0|User ready to start using the app|Make reservations based on custom input and edit them where necessary|Get familiar with inputting|
|v2.1|Expert user|Ascertain the error in my input based on the error messages from the application|Quickly troubleshoot any mistakes that would slow down my work|
|v2.1|Expert user|View all reservations currently under a specific travel package|Optimize that travel package according to user’s feedback|
|v2.1|Expert user|Sort all packages according to date, price or vacancies|Give better recommendations to customers|


## Non-Functional Requirements

{Give non-functional requirements}
### Performance Requirements
- Should work on any mainstream OS as long as it has Java 11 or above installed.

### Usability
- A user with above average typing speed for regular English text (i.e. not code, not system admin commands) should be able to accomplish most of the tasks faster using commands than using the mouse.
- Prompts and instructions must be in proper and concise sentences for ease of understanding.

## Glossary

* *glossary item* - Definition
* Packages - Travel Package within the agency's database
* Reservations - Reservation of travel package made by one customer through the app


### Summary of User Commands

| Command | Format Examples |
| ------- |-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|help| help <br/> (prints details of all commands) |
|packages| packages <br/> (prints details of all packages) |
|info| info {num} (num <= number of available packages) <br/> e.g. info 2 |
|all| all <br/> Will prompt user to enter 1,2,3 to print out packages sorted by date, price or vacancies. 4 to return. |
|add| add {package_name},{ID},{startDate},{endDate},{hotel},{price},{country},{vacancies} <br/> e.g. add Skiing Trip,1,23/2/2022,24/2/2022,hotelName,90.99,Singapore,20 <br/> adds a TravelPackage |
|delete| delete {num} (num <= number of available packages) <br/> e.g. delete 2 <br/> delete a TravelPackage |
|reserve| reserve {package_number},{contact_name},{contact_number},{number_pax} <br/> e.g reserve 3,John,91234567,3 |
|remove| remove {package_number},{contact_number} <br/> e.g remove 1,8888888 <br/> remove an existing reservation |
|reservations| reservations {package_number} <br/> eg. reservations 2 <br/> print all reservations for a given travelPackageID |
|addHotel| addHotel {hotel_id},{hotel_name},{country},{price},{package_number} <br/> eg. addHotel 1,Hotel99,Singapore,100,1 <br/> Add a Hotel to the Itinerary |
|hotels| hotels {package_number} <br/> eg. hotels 1 <br/> View all hotels offering this package |

### Test Case 1

New employees can enter `packages` to view all available packages by the agency.

Additionally, they can enter `info {package number}` to view more in-depth information about the package.

![image](https://user-images.githubusercontent.com/64303732/161110520-8ed18ddc-b356-43d5-95ed-7df5ca2de91d.png)

Employees can also input new reservations using `reserve {package_number},{contact_name},{contact_number},{number_pax}`

They can then view and verify reservations for that package using `reservation {package_number}`

![image](https://user-images.githubusercontent.com/64303732/161111482-a2f9600d-d1f0-45b1-9a51-ef28848e4b57.png)

![image](https://user-images.githubusercontent.com/64303732/161111551-c1acfd1e-90f3-426e-b8e3-175f050dba42.png)


## Feature - Help Command
Aim: Displays a list of all available commands that the user can refer to as a guide

![image](HelpCommand.png)



## Feature - Storage
#### Initialisation (Loading Data)
The sequence diagram that shows how `Storage` is created and the data is loaded from the saved files when the program is initialised is shown below:
![](LoadFileSeqDiag.png)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using a consistent UML diagramming software unless the primary has limitations.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Missing colon in front of the classes. Refer to the handout for more information on the syntax.
  2. Missing activation bats for calling getPackage(), saveTravelPackage(), instantiating FileWriter and write (text)*.
  3. Consider rephrasing the condition for the loop (until all elements are iterated)
  4. Consider adding cross to indicate EoL, if any.
  • If you would like to omit the information please ensure that there would not be a loss of data (e.g. can others tell that FileWriter was instantiated in Storage or before?)


1. `TARBS` creates a Storage object with the relevant file name (`filePath`).
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instantiation of an object should involve the use of a constructor, which has activation bars connected to the Storage. Compare:
image
and
image

2. `TARBS` then calls the `createPackages()` method of the Storage class
3. `storage` will call the `parseSavedFile()` method, which initiates a while loop that iterates through the text file and processes the string data using the respective `parse` methods.
4. A new `TravelPackage` object is constructed with the relevant data.
5. A new `Packages` object is created using the `TravelPackage` object and returned back to `TARBS`.

#### Saving data
The sequence diagram that shows how `Storage` is used to save the current list of travel packages and reservations is shown below: </br>

![](SaveFilesSeqDiag.png)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as previous comment


1. `TARBS` calls the `savePackageToFile()` method of `storage`, passing in the `packages` object.
2. `storage` will then use a loop to iteratively retrieve the data in string format from the individual `TravelPackage` objects.
3. `storage` will create a new `FileWriter` object to write the string data into a text file.

## Feature - Parser
The sequence diagram shows an example of how a user input is parsed and returns a new `Command`.

For simplicity, `ByeCommand` is shown here:

## Instructions for manual testing
![image](https://user-images.githubusercontent.com/53790951/160289728-5a17b2ea-0599-48f4-a18b-cadfbbcbfb11.png)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps can add an activation bar when you call the constructor of ByeCommand?
image

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it better to include User in the left most of the sequence diagram?
image

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
Similar to the storage diagram, maybe the highlighted line should be a solid line

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this vertical bar extending below the boundary of the alt box be there?

Also, I think this diagram would be clearer if it came with a step-by-step explanation.

image

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There should be a constructor activation bar here that should also return the instantiated object.

Screenshot 2022-03-31 at 11 42 04 AM

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Consider moving the condition for the [alt] path to beside the icon, instead of on the first method call.
  2. Consider adding crosses to indicate EoL if applicable
  3. The classes are lacking a colon
  4. Is there any code after return ByeCommand? If not consider ending both activation bars on the return arrow.


{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}
Binary file added docs/HelpCommand.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/LoadFileSeqDiag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 5 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
# Duke
# Travel Agency Reservation Booking System - TARBS
- TARBS is a CLI application made using Java 11 to help staff of a Travel Agency company keep track of its' travel packages, as well as customer's reservations.
- Some features include creating and storing travel packages, viewing of said packages and the ability to record reservations made by customers using their mobile numbers.
- It is also user-friendly as it includes the ability to delete any entries that were keyed in wrongly - be it packages or reservations.

{Give product intro here}
- Do refer to the links below for more information on the application!

Useful links:
* [User Guide](UserGuide.md)
Expand Down
Binary file added docs/SaveFilesSeqDiag.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
128 changes: 113 additions & 15 deletions docs/UserGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,139 @@

## Introduction

{Give a product intro}
Travel Agency Reservation Booking System (TARBS) is a desktop app for managing reservations for travel packages and tourist attractions, optimised for use via a Command Line Interface (CLI). If you can type fast, TARBS can help to improve efficiency of adding and editing reservations, amongst many other features.

## Quick Start

{Give steps to get started quickly}
### Why do we need TARBS?
Travel agencies often have to manage multiple customers and their respective bookings or plans.

## Quick Start

1. Ensure that you have Java 11 or above installed.
1. Down the latest version of `Duke` from [here](http://link.to/duke).
1. Down the latest version of `TARBS` from [here](https://github.com/AY2122S2-CS2113-F10-3/tp/releases).

## Features

{Give detailed description of each feature}
### Quick Help: `help`
Print detailed instructions on the available commands that users may input.

Usage: `help`

### Show all packages: `packages`

View a list of all available packages

Usage: `packages`

### Viewing a package: `info`
View a specified Travel Package from the list of Packages based on the package ID.

Format: `info {package_number}`

Example of usage:

`info 2`

### Show packages sorted by starting date, price or vacancies : `all`
View list of packages sorted by ascending date or price and descending vacancies.

Format: `all`

Example of usage:
```
all

Sort packages by:
1. Date (Earliest to Latest)
2. Number of vacancies left
3. Price
4. Return to main menu.

Enter 1-4
```




### Adding a package: `add`
Adds a new Travel Package to the list of Packages.

Format: `add {package_name},{package_number},{startDate},{endDate},{hotel},{price},{country},{vacancies}`

* The `startDate` and `endDate` must be in the format DD/MM/YYYY.
* The `price` can only contain numbers or decimal points.
* `package_number` should be unique.


### Adding a todo: `todo`
Adds a new item to the list of todo items.
Example of usage:

`add Skiing Trip,1,23/02/2022,24/02/2022,hotelName,90.99,Singapore,20`


### Deleting a package: `delete`
Delete a Travel Package from the list of Packages based on the package ID.

Format: `delete {package_number}`

Example of usage:

`delete 2`

Format: `todo n/TODO_NAME d/DEADLINE`
### Placing a reservation: `reserve`
Add a reservation to a Travel Package.

* The `DEADLINE` can be in a natural language format.
* The `TODO_NAME` cannot contain punctuation.
Format: `reserve {package_number},{contact_name},{contact_number},{number_pax}`

Example of usage:

`todo n/Write the rest of the User Guide d/next week`
`reserve 3,John,91234567,3`

### Removing a reservation: `remove`
Remove a reservation from a Travel Package using packageID and contact number.

Format: `remove {package_number},{contact_number}`

Example of usage:

`todo n/Refactor the User Guide to remove passive voice d/13/04/2020`
`remove 1,8888888`

### View reservations: `reservations`
View reservations booked in a Travel Package.

Format: `reservations {package_number}`

Example of usage:

`reservations 2`

### Exit application:
Format and Usage:
```
bye
```

## FAQ

**Q**: How do I transfer my data to another computer?

**A**: {your answer here}
**A**: When starting the application, data.txt will be created if there isn't one already. Simply place the data.txt with the executable JAR file on the new computer and you are good to go.



## Command Summary

{Give a 'cheat sheet' of commands here}

* Add todo `todo n/TODO_NAME d/DEADLINE`
| Command | Syntax |
| --- |:------------------------------------------------------------------------------------------------|
| help | help |
| packages | packages |
| info | info {package_number} |
| all | all |
| add | add {package_name},{package_number},{startDate},{endDate},{hotel},{price},{country},{max_vacancies} |
| delete | delete {package_number} |
| reserve | reserve {package_number},{contact_name},{contact_number},{number_pax} |
| remove | remove {package_number},{contact_number} |
| reservations | reservations {package_number} |



1 change: 1 addition & 0 deletions docs/_config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
theme: jekyll-theme-minimal
Loading