MDL-37834 assign: avoid newlines in status column of csv

Previously we were generating a CSV file with newlines in it, which
seems to cause problems importing into some versions of MS Excel.

Instead seperate status lines by '-' - this column is only used to
provide context to the teacher in the spreadsheet.
This commit is contained in:
Dan Poltawski
2015-11-20 18:36:30 +00:00
parent 2b11b94c0c
commit b58d059525
+1 -1
View File
@@ -972,7 +972,7 @@ class assign_grading_table extends table_sql implements renderable {
}
if ($this->is_downloading()) {
$o = strip_tags(str_replace('</div>', "\n", $o));
$o = strip_tags(rtrim(str_replace('</div>', ' - ', $o), '- '));
}
return $o;