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

Jhchen/ft manage account #157

Merged
merged 11 commits into from Nov 4, 2019
Merged

Jhchen/ft manage account #157

merged 11 commits into from Nov 4, 2019

Conversation

ChenJiehan318
Copy link

add balance field to the account
(currently all other account commands are able to update the balance displayed in the list.. except for account list... )
closes #136

Copy link

@kenneth-fung kenneth-fung left a comment

Choose a reason for hiding this comment

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

Seems good. But I think the position of the balance in the GUI should be changed, unless I'm reading the code wrong.

src/main/java/budgetbuddy/model/account/Account.java Outdated Show resolved Hide resolved
Comment on lines 113 to 173
@Override
public String toString() {
return getName().toString() + " (" + getDescription().toString() + ")";
}

Choose a reason for hiding this comment

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

I don't think the user will ever see the result of toString(), so up to you if you want to add the balance in it too.

src/main/resources/view/AccountCard.fxml Outdated Show resolved Hide resolved
Copy link

@tcgj tcgj left a comment

Choose a reason for hiding this comment

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

Looks fine, but take a look at Kenneth's comments in particular.

@coveralls
Copy link

coveralls commented Nov 4, 2019

Coverage Status

Coverage decreased (-0.03%) to 35.695% when pulling 83ddc65 on jhchen/ft-manage-account into 8abbf41 on master.

kenneth-fung
kenneth-fung previously approved these changes Nov 4, 2019
Copy link

@kenneth-fung kenneth-fung left a comment

Choose a reason for hiding this comment

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

Looks good.

Comment on lines +84 to +85
checkBalanceValidity(balance = balance + toAdd.getAmount().toLong());
balance = balance + toAdd.getAmount().toLong();
} else {
checkBalanceValidity(balance = balance - toAdd.getAmount().toLong());
balance = balance - toAdd.getAmount().toLong();
Copy link

Choose a reason for hiding this comment

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

Not sure why there's assignment within the arguments here

Copy link

@thaowei thaowei left a comment

Choose a reason for hiding this comment

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

Rebased.

@thaowei thaowei merged commit 83ddc65 into master Nov 4, 2019
@thaowei thaowei added this to the v1.4 milestone Nov 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Numbering in UI is not showing properly if size of list is below 3
5 participants