Skip to content

Commit

Permalink
Merge pull request #222 from yyangdaa/DG-Update
Browse files Browse the repository at this point in the history
Dg update
  • Loading branch information
yyangdaa authored Apr 13, 2024
2 parents b044708 + 4fcf619 commit a0d9860
Show file tree
Hide file tree
Showing 9 changed files with 230 additions and 35 deletions.
2 changes: 1 addition & 1 deletion data/DefaultCurrency.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Default Currency: USD
Default Currency: SGD
10 changes: 5 additions & 5 deletions docs/AboutUs.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@

Display | Name | Github Profile | Portfolio
--------|:-------------:|:-----------------------------------------:|:---------:
![](https://via.placeholder.com/100.png?text=Photo) | Zhang Yangda | [Github](https://github.com/yyangdaa) | [Portfolio](docs/team/yyangdaa.md)
![](https://via.placeholder.com/100.png?text=Photo) | Dheekshitha | [Github](https://github.com/Dheekshitha2) | [Portfolio](docs/team/Dheekshitha2.md)
![](https://via.placeholder.com/100.png?text=Photo) | Jasra Zainab | [Github](https://github.com/jasraa) | [Portfolio](docs/team/jasraa.md)
![](https://via.placeholder.com/100.png?text=Photo) | Chan Jun Rong | [Github](https://github.com/itsmejr257) | [Portfolio](docs/team/itsmejr257.md)
![](https://via.placeholder.com/100.png?text=Photo) | Soh Wei Jie | [Github](https://github.com/sweijie24) | [Portfolio](docs/team/sweijie24.md)
![](https://via.placeholder.com/100.png?text=Photo) | Zhang Yangda | [Github](https://github.com/yyangdaa) | [Portfolio](docs/team/yyangdaa.md)
![](https://via.placeholder.com/100.png?text=Photo) | Dheekshitha | [Github](https://github.com/Dheekshitha2) | [Portfolio](docs/team/Dheekshitha2.md)
![](https://via.placeholder.com/100.png?text=Photo) | Jasra Zainab | [Github](https://github.com/jasraa) | [Portfolio](docs/team/jasraa.md)
![](https://via.placeholder.com/100.png?text=Photo) | Chan Jun Rong | [Github](https://github.com/itsmejr257) | [Portfolio](docs/team/itsmejr257.md)
![](https://via.placeholder.com/100.png?text=Photo) | Soh Wei Jie | [Github](https://github.com/sweijie24) | [Portfolio](docs/team/sweijie24.md)

201 changes: 196 additions & 5 deletions docs/DeveloperGuide.md

Large diffs are not rendered by default.

28 changes: 16 additions & 12 deletions docs/UserGuide.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ command to run the application.
## 3. Features

### 3.1 Display Commands : `menu`

Displays the corresponding features of BudgetBuddy

Format: `menu [INDEX]`
Expand Down Expand Up @@ -108,19 +109,21 @@ Example of Usage:

`add savings c/Salary a/500.50`

### 3.4 Add Split Expenses
Add expenses that are meant for splitting among friends or colleague
### Add Shared Bill
Add bills that are meant for splitting among friends or colleague
### 3.4 Add Shared Bill
Add bills that are meant for splitting among friends or colleague

Format: `split expenses a/AMOUNT n/NUMBER_OF_PEOPLE d/DESCRIPTION`
Format: `add shared bill a/AMOUNT n/NUMBER_OF_PEOPLE d/DESCRIPTION`

* Increments split expenses
* Increments shared bills
* The `AMOUNT` must be a positive number
* The `NUMER_OF_PEOPLE` must be a positive integer.
* The `DESCRIPTION` can be any string

Example of usage:

`split expenses a/100 n/10 d/Lunch
`add shared bill a/100 n/10 d/Lunch`

### 3.5 Edit Savings: `edit savings`
Edit Savings that have been added previously.
Expand Down Expand Up @@ -264,24 +267,25 @@ Expected Output (Filtered Category) :

### 3.11 Check splitted expenses `check splitted expenses`

Check expenses
Check Split Bills

Format: `check split bills`

Format: `check splitted expenses`
* the system will list all bills that have been split.
* The listed bills include details such as the description, the number of people and the amount payable by each person.

* the system will list all splitted expenses.
* The listed splitted expenses include details such as the total amount spent, number of people in the bill, description and the amount payable by each person.

### 3.12 Settle splitted expenses `settle expense`
### 3.12 Settle bill `settle bill`

Settle splitted expenses

Format `settle i/Index`
Format `settle bill i/Index`

* The system will settle the splitted expense corresponding to `Index`
* `Index` must be a positive integer

Example of usage:
`settle i/2`: Delete splitexpense of index 2 listed in splittedexpenses tracker
`settle bill i/2`: Delete bill of index 2 listed in splittedexpenses tracker

### 3.13 Finding expenses : `find expenses`

Expand Down
6 changes: 3 additions & 3 deletions src/main/java/seedu/budgetbuddy/Parser.java
Original file line number Diff line number Diff line change
Expand Up @@ -129,11 +129,11 @@ public Boolean isConvertCurrencyCommand(String input) {
}

public Boolean isSplitExpenseCommand(String input) {
return input.startsWith("split expenses");
return input.startsWith("add shared bill");
}

public Boolean isListSplitExpenseCommand(String input) {
return input.contentEquals("check splitted expenses");
return input.contentEquals("check split bills");
}

public Boolean isSetBudgetCommand(String input){
Expand All @@ -149,7 +149,7 @@ public boolean isListBudgetCommand(String input){
}

public Boolean isSettleSplitExpenseCommand(String input) {
return input.startsWith("settle");
return input.startsWith("settle bill");
}

public Boolean isGetExpensesInsightsCommand(String input) {
Expand Down
12 changes: 6 additions & 6 deletions src/main/java/seedu/budgetbuddy/Ui.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public void showWelcome() {
System.out.println("0. Display the whole menu");
System.out.println("1. Manage Expenses 2. View Expenses");
System.out.println("3. View Expenses 4. View Savings");
System.out.println("5. Find Expenses 6. Split Expenses");
System.out.println("5. Find Expenses 6. Divide Bills");
System.out.println("7. Manage Recurring Bills 8. Change Currency");
System.out.println("9. Manage Budget 10. Get Graphical Insights");
System.out.println(DIVIDER);
Expand All @@ -35,7 +35,7 @@ public void showMenuTitles() {
System.out.println("0. Display the whole menu");
System.out.println("1. Manage Expenses 3. View Expenses");
System.out.println("2. Manage Savings 4. View Savings");
System.out.println("5. Find Expenses 6. Split Expenses");
System.out.println("5. Find Expenses 6. Divide Bills");
System.out.println("7. Manage Recurring Bills 8. Change Currency");
System.out.println("9. Manage Budget 10. Get Graphical Insights");
System.out.println("Use 'menu INDEX' to select an option");
Expand Down Expand Up @@ -85,10 +85,10 @@ public void showMenuItem(int index) {
"(Choose the parameters according to what you wish to search for)");
break;
case 6:
System.out.println("Split Expenses");
System.out.println("split expenses a/AMOUNT n/NUMBER_OF_PEOPLE d/DESCRIPTION");
System.out.println("check splitted expenses");
System.out.println("settle i/INDEX");
System.out.println("add shared bills");
System.out.println("add shared bill a/AMOUNT n/NUMBER_OF_PEOPLE d/DESCRIPTION");
System.out.println("check split bills");
System.out.println("settle bill i/INDEX");
break;
case 7:
System.out.println("Recurring Bills");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public String getDescription() {
public void execute() {
try {
splitexpenses.addSplitExpense(this.amount, this.numberOfPeople, this.description);
System.out.println("SplitExpense Added: " + "$" + amount + " spent by " +
System.out.println("Shared Bill Added: " + "$" + amount + " spent by " +
numberOfPeople + " persons. Description: " + description);
} catch (BudgetBuddyException e) {
System.out.println("An error occurred while adding expense.");
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/seedu/budgetbuddy/commons/ExpenseList.java
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ public void addExpense(String category, String amount, String description) throw
expenses.add(expense);

System.out.println("Expense added: " + matchedCategory + " of $" + String.format("%.2f", amountAsDouble)
+ " with description: " + description);
+ " Description: " + description);
}


Expand Down
2 changes: 1 addition & 1 deletion text-ui-test/EXPECTED.TXT
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ __________________________________________________
0. Display the whole menu
1. Manage Expenses 2. View Expenses
3. View Expenses 4. View Savings
5. Find Expenses 6. Split Expenses
5. Find Expenses 6. Divide Bills
7. Manage Recurring Bills 8. Change Currency
9. Manage Budget 10. Get Graphical Insights
__________________________________________________
Expand Down

0 comments on commit a0d9860

Please sign in to comment.