"Assignment","Student","Submitted?","Points Available","Automatic Score","Teacher Score","Days Late","Late Penalty","Effective Score"
<% @subs.each do |sub| %>
<% if sub.new_record? %>
"<%= sub.assignment.name %>","<%= sub.user.name %>","no",<%= sub.assignment.points_available %>,0,0,0,0,0
<% else %>
"<%= sub.assignment.name %>","<%= sub.user.name %>","yes",<%= sub.assignment.points_available %>,<%= sub.raw_score %>,<%= sub.teacher_score %>,<%= sub.days_late %>,<%= sub.late_penalty %>,<%= sub.score %>
<% end %>
<% end %>
"Assignment","Student","Last Name","Submitted?","Points Available","Automatic Score","Teacher Score","Days Late","Late Penalty","Effective Score"
<% @subs.each do |sub| %>
<% if sub.new_record? %>
"<%= sub.assignment.name %>","<%= sub.user.name %>","<%= sub.user.surname %>","no",<%= sub.assignment.points_available %>,0,0,0,0,0
<% else %>
"<%= sub.assignment.name %>","<%= sub.user.name %>","<%= sub.user.surname %>","yes",<%= sub.assignment.points_available %>,<%= sub.raw_score %>,<%= sub.teacher_score %>,<%= sub.days_late %>,<%= sub.late_penalty %>,<%= sub.score %>
<% end %>
<% end %>

Add a "last name" field to the course grade CSV.
Add a "last name" field to the course grade CSV.
