-
Notifications
You must be signed in to change notification settings - Fork 5
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
Implement analytics GUI (Part 2 - Piechart Display) #99
Implement analytics GUI (Part 2 - Piechart Display) #99
Conversation
Encapsulate analytics and benchmark values in a singular class
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #99 +/- ##
============================================
- Coverage 48.81% 47.34% -1.48%
Complexity 431 431
============================================
Files 98 99 +1
Lines 2157 2224 +67
Branches 216 224 +8
============================================
Hits 1053 1053
- Misses 1060 1127 +67
Partials 44 44 ☔ View full report in Codecov by Sentry. |
if (analytics.getEarliestReturnDate() == null || earliestReturnDate == null) { | ||
return null; | ||
} | ||
LocalDate target = analytics.getEarliestReturnDate().toInstant().atZone(ZoneId.systemDefault()).toLocalDate(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should probably abstract this conversion of dates in a later iteration.
impactChart.setData(impactData); | ||
impactIndex.setText(String.format("%.2f", data.getImpactIndex() * 100) + "%"); | ||
} | ||
if (data.getUrgencyIndex() == null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's probably a better to handle these null conditions. Something to consider for future iterations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
2cdf8d3
into
AY2324S2-CS2103T-W13-1:master
Resolves #84
Feature added
A GUI display for analytics has been implemented. It showcases 3 values in piecharts - Reliability, Impact and Urgency
Changelog
DashboardData
has been added to encapsulate current contact's analytics and the max values of all existing loans. These max values are used for reference in calculating Impact and Urgency indicesNotes
Currently handled cases