This repository has been archived by the owner on Jan 10, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 86
Average grade improvement #1439
Merged
tobiasjungmann
merged 75 commits into
TUM-Dev:master
from
tobiasjungmann:1426_Average_Grade_Improvement
Jul 28, 2022
Merged
Average grade improvement #1439
tobiasjungmann
merged 75 commits into
TUM-Dev:master
from
tobiasjungmann:1426_Average_Grade_Improvement
Jul 28, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ted grades in the diagrams.
…vent occasionally crashes on closing
…ted grades in the diagrams.
* Fix ktlint errors * Help out Kotlins type inference * Move long test strings from code to seperate json files * Bump Robolectric version to 4.8
…nts (TUM-Dev#1434) * Update appcompat, fragment and fix findViewById() in Fragments * fix formatting Co-authored-by: Kordian Bruck <[email protected]>
…into 1426_Average_Grade_Improvement # Conflicts: # app/src/main/java/de/tum/in/tumcampusapp/component/tumui/grades/GradesFragment.kt
The rebase was more or less successful. Now the branch can be merged into the master again without conflicts. |
@kordianbruck did you already review it apart from the rebase so we can merge it? |
Thank you for your review, the questionmark is now fixed. |
COM8
suggested changes
Jul 27, 2022
app/src/main/java/de/tum/in/tumcampusapp/component/tumui/grades/ExamListAdapter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/de/tum/in/tumcampusapp/component/tumui/grades/ExamListAdapter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/de/tum/in/tumcampusapp/component/tumui/grades/ExamListAdapter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/de/tum/in/tumcampusapp/component/tumui/grades/ExamListAdapter.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/de/tum/in/tumcampusapp/component/tumui/grades/ExamListAdapter.kt
Outdated
Show resolved
Hide resolved
…s/ExamListAdapter.kt Co-authored-by: Fabian Sauter <[email protected]>
Co-authored-by: Fabian Sauter <[email protected]>
Co-authored-by: Fabian Sauter <[email protected]>
COM8
approved these changes
Jul 28, 2022
COM8
approved these changes
Jul 28, 2022
Bentipa
approved these changes
Jul 28, 2022
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.
Feature wise approved, @COM8 did the code review so fine to go
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue
This is an improves the grade view as it was described in Issue 1246. Users can enter their own values for a weight and the credits for a course in a separate edit mode. Additionally, new courses can be added and removed.
Changes
UI
The UI looks identical to the previous version at first glance. The diagram is a little bit larger and a gear icon in the top right corner was added.
This allows to switch to the newly created edit mode:
The number of credits and the courses weight can be entered for every exam individually. Hiding a grade removes the grade color from the
TextView
on the right and deactivatesEditTexts
. Hidden grade won't be used to compute the average grade and are not included in the diagrams.Resetting a grade resets all parameters to the default.
Adding a new grade is possible in the edit mode with the floating action button in the bottom right corner. All values, which can be entered are validated before the exam is created. Every manually created exam can be deleted with the delete button in the top right corner of the exam.
Last but not least, the spinner in the top bar to only select grades for a certain program is only shown if the user has two or more programs to choose from.
Logic
A json String of all exam objects (the grades) is now saved in the shared preferences. This string is used to load the list of exams instead of the previously used cache.
Changes for each grade are stored directly in the shared preferences and are handled by the method
storeExamListInSharedPreferences
.loadExamListFromSharedPreferences
Loads the stored exam object from the shared preferences.