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

Prioritize evaluations with finished grading for review #1668

Merged
merged 8 commits into from
Apr 18, 2022
8 changes: 7 additions & 1 deletion evap/staff/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -1452,7 +1452,13 @@ def evaluation_textanswers(request, semester_id, evaluation_id):
request.session["review-visited"] = visited

sections = evaluation_sections + contributor_sections
template_data.update(dict(sections=sections, next_evaluations=next_evaluations))
# Evaluations where the grading process is finished should be shown first, need to be sorted in Python
template_data.update(
dict(
sections=sections,
next_evaluations=sorted(next_evaluations, key=lambda e: e.grading_process_is_finished, reverse=True),
richardebeling marked this conversation as resolved.
Show resolved Hide resolved
)
)
return render(request, "staff_evaluation_textanswers_quick.html", template_data)

template_data.update(dict(evaluation_sections=evaluation_sections, contributor_sections=contributor_sections))
Expand Down