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

Modify 'edit' command to depend on UI state #107

Merged

Conversation

ianyong
Copy link
Member

@ianyong ianyong commented Oct 12, 2020

Changes:

  • Add generic edit command that returns one of the 2 specialised edit commands depending on UI state.
  • Update test cases accordingly.
  • Fix hash code for FinanceTracker.
  • Fix addExpense and addIncome methods of ModelManager updating the wrong list.

Resolves #86.

@ianyong ianyong added type.enhancement 👍 New feature or request priority.medium 🥈 Todo for current iteration labels Oct 12, 2020
@ianyong ianyong added this to the v1.2 milestone Oct 12, 2020
@codecov-io
Copy link

codecov-io commented Oct 12, 2020

Codecov Report

Merging #107 into master will increase coverage by 1.10%.
The diff coverage is 85.71%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master     #107      +/-   ##
============================================
+ Coverage     67.99%   69.10%   +1.10%     
- Complexity      485      512      +27     
============================================
  Files            91       93       +2     
  Lines          1653     1738      +85     
  Branches        155      165      +10     
============================================
+ Hits           1124     1201      +77     
+ Misses          485      484       -1     
- Partials         44       53       +9     
Impacted Files Coverage Δ Complexity Δ
...s1_cs2103_w16_3/finesse/commons/core/Messages.java 0.00% <ø> (ø) 0.00 <0.00> (ø)
...1s1_cs2103_w16_3/finesse/model/FinanceTracker.java 83.33% <0.00%> (+12.50%) 19.00 <0.00> (+2.00)
...021s1_cs2103_w16_3/finesse/model/ModelManager.java 87.67% <50.00%> (+12.32%) 29.00 <0.00> (+3.00)
...6_3/finesse/logic/commands/EditExpenseCommand.java 84.61% <84.61%> (ø) 8.00 <8.00> (?)
...16_3/finesse/logic/commands/EditIncomeCommand.java 84.61% <84.61%> (ø) 8.00 <8.00> (?)
...2103_w16_3/finesse/logic/commands/EditCommand.java 96.77% <100.00%> (+0.10%) 12.00 <3.00> (+2.00)
...6_3/finesse/logic/parser/FinanceTrackerParser.java 92.72% <100.00%> (-2.01%) 29.00 <0.00> (+3.00) ⬇️
...va/ay2021s1_cs2103_w16_3/finesse/ui/UiManager.java 0.00% <0.00%> (ø) 0.00% <0.00%> (ø%)
...a/ay2021s1_cs2103_w16_3/finesse/ui/CommandBox.java 0.00% <0.00%> (ø) 0.00% <0.00%> (ø%)
... and 9 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a1db477...b7af29a. Read the comment docs.

@ianyong ianyong marked this pull request as ready for review October 13, 2020 07:20
@ianyong ianyong requested a review from a team October 13, 2020 07:20
@ianyong ianyong requested review from zhaojj2209 and a team October 13, 2020 08:38
Copy link

@zhaojj2209 zhaojj2209 left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link

@yongping827 yongping827 left a comment

Choose a reason for hiding this comment

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

LGTM

@yongping827 yongping827 merged commit 6b3aa2b into AY2021S1-CS2103T-W16-3:master Oct 13, 2020
This was referenced Oct 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority.medium 🥈 Todo for current iteration type.enhancement 👍 New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Modify 'edit' command to depend on UI state
4 participants