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

Include submission times in grade book exports #1375

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions server/jobs/export_grades.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,14 @@ def get_headers(assignments):
if new_headers:
new_assignments.append(assignment)
headers.extend(new_headers)
headers.append('{} (Submitted At)'.format(assignment.display_name))
return headers, new_assignments

def export_student_grades(student, assignments):
student_row = [student.user.email, student.sid]
for assign in assignments:
status = assign.user_status(student.user)
submission_time = status.subm_time
scores = {s.kind.lower(): s.score for s in status.scores}
scores = score_policy(scores)
score_types = get_score_types(assign)
Expand All @@ -62,6 +64,10 @@ def export_student_grades(student, assignments):
student_row.append(scores[score_type])
else:
student_row.append(0)
if submission_time:
student_row.append(submission_time)
else:
student_row.append('No Submission')
return student_row


Expand Down