[GH-1487] fix csv export fail (#1533)

* fix csv export fail
This commit is contained in:
DeeJayBro 2021-10-13 17:59:29 +02:00 committed by GitHub
parent f38db2bce9
commit cad6884fda
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -69,6 +69,9 @@ class CsvExporter {
if (template.type === 'number') {
const numericValue = propertyValue ? Number(propertyValue).toString() : ''
row.push(numericValue)
} else if (template.type === 'multiSelect') {
const multiSelectValue = ((displayValue as unknown || []) as string[]).join('|')
row.push(multiSelectValue)
} else {
// Export as string
row.push(`"${this.encodeText(displayValue)}"`)