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

[Feature:RainbowGrades] Adding Link to Gradeables #83

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

ryvaru
Copy link

@ryvaru ryvaru commented Nov 6, 2024

Closes #10433 (Submitty/Submitty#10433)

What is the current behavior?
Currently, students can only see their grade for a specific gradeable on Rainbow Grades, and would have to search through gradeables to see their full report.

What is the new behavior?
Now, when students see their grade on Rainbow Grades, they can just click on it and it sends them to see their full report directly. This is more convenient and helpful for students. Note that for a gradeable to have a link, the gradeable must be released AND its type must be an Electronic File Upload, nothing else will work.

image

Other information?
This PR fixes and reimplements the code made in PR #81.

To test: Go to a course --> Make sure Rainbow Grades viewing is enabled --> Generate Grade Summaries --> Web-Based Rainbow Grades Generation --> (Drop items into bucket and display at least grade_summary and grade_details) --> Build --> View changes on Rainbow Grades by clicking on a gradeable.

Added a function getCourseDetails(), which returns the base url, term, and course, which helps in getting the total link to a specific gradeable on the output page. These changes are untested.
From the MakefileHelper, I used REPORTS_DIRECTORY to make the link work for all courses and semesters. Fixed the URL.
@ryvaru ryvaru marked this pull request as draft November 12, 2024 05:44
Made an extra check to see that the gradeable has actually been released to view the link to the gradeable itself, otherwise this would be useless. Also, added the blue box permanently to be displayed along with the gradeable names that have links.
The logic here is that starting from DISPLAY_GRADE_DETAILS, I find a random user (the first user after AVERAGE AND STDDEV, could be the instructor who opened the course). Then, I call the getGreadeableType function to go to their summary json and scan for the gradeable id. If the gradeable id is found, I return the value of gradeable_type.
@ryvaru ryvaru marked this pull request as ready for review November 19, 2024 08:02
@ryvaru ryvaru assigned Kush-Raval and unassigned Kush-Raval Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In Review
Development

Successfully merging this pull request may close these issues.

2 participants