Changed CSV newline escape replacement character

This commit is contained in:
neviyn 2020-09-29 11:48:47 +01:00
parent cdb156c818
commit d4226920d8

View File

@ -93,7 +93,7 @@ data class Observation(
) {
fun toCsvFormat(): String {
fun escapeSpecialCharacters(data: String): String {
return data.replace("\"", "\"\"").replace("\n", "")
return data.replace("\"", "\"\"").replace("\n", ";")
}
val dataPortion = "${date.toString("dd/MM/yyyy")},\"$person, ${type.name} ${scenarios.joinToString { it.title }}\"," +
"\"Training\",\"Operations - Shift Operations\",\"${site.name}\",\"N/A\"," +