Add grade to export results

This commit is contained in:
Matt Young 2024-11-02 10:37:41 -05:00
parent 0041c62008
commit 7b0729381b
1 changed files with 2 additions and 1 deletions

View File

@ -23,7 +23,7 @@ class GetExportData
// Audition, Rank, Name, School, Score, Flags or Seat // Audition, Rank, Name, School, Score, Flags or Seat
$ranker = App::make(RankAuditionEntries::class); $ranker = App::make(RankAuditionEntries::class);
$exportRows = [ $exportRows = [
'Audition,Rank,Student Name,School,Score,Seat or Flag', 'Audition,Rank,Student Name,School,Grade,Score,Seat or Flag',
]; ];
$events = Event::all(); $events = Event::all();
foreach ($events as $event) { foreach ($events as $event) {
@ -36,6 +36,7 @@ class GetExportData
$thisRow .= ','; $thisRow .= ',';
$thisRow .= $entry->student->full_name().','; $thisRow .= $entry->student->full_name().',';
$thisRow .= $entry->student->school->name.','; $thisRow .= $entry->student->school->name.',';
$thisRow .= $entry->student->grade.',';
$thisRow .= $entry->score_totals[0] ?? ''; $thisRow .= $entry->score_totals[0] ?? '';
$thisRow .= ','; $thisRow .= ',';
if ($entry->hasFlag('failed_prelim')) { if ($entry->hasFlag('failed_prelim')) {