frontend
frontend copied to clipboard
Add Publish Grading Feature
Description
(closes #2522)
Currently, the grading states design and business logic cause ambiguity with resubmission of assessments being assumed to be graded immediately, and with grades being displayed when they should not.
This feature aims to solve this issue by introducing a new grading state published
and a new backend boolean is_grading_published
, allowing explicit publishing of student's grades on the frontend and preventing the fetching of grades if they have yet to be published, hence creating a better logic flow.
This pull request contains changes to be made to the frontend to enable this new feature.
Type of change
- [ ] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [x] This change requires a documentation update
- [ ] Code quality improvements
How to test
(Import your own assessment XML files for testing if possible)
- Using a test student account, submit an assessment
- Using a test staff/admin account, grade some but not all questions in the assessment
- Staff/admin should not be able to publish grades if not all questions have been graded
- Using a test staff/admin account, complete grading the assessment
- The grades should not be visible to the student even upon all questions being graded
- Using a test staff/admin account, publish the assessment grades using the new UI button in the grading dashboard
- The grades should now be visible to the student
- Using a test staff/admin account, unsubmit the assessment
- The assessment should be unpublished automatically and the student should not be able to view any XP for that assessment, even if the student resubmits again
- Students should still be able to view comments
- Once regrading is done, publish grades again and the student should be able to view the grades
- Staff/Admin is also able to unpublish the grades after publishing them if required
Checklist
- [x] I have tested this code
- [ ] I have updated the documentation
@emptygx can we fix the failing tests?
@emptygx can we fix the failing tests?
Hey so sorry but I am not too sure how to go about fixing them, could I have some guidance on this? Thank you!
Superseded by #2856.