Skip to content

Commit ea569ff

Browse files
authored
expand tags in csv (#8258)
Fixes: #8256
1 parent fc44df7 commit ea569ff

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

ui/src/views/network/AclListRulesTab.vue

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,17 @@ export default {
334334
result += columnDelimiter
335335
}
336336
337-
result += typeof item[key] === 'string' && item[key].includes(columnDelimiter) ? `"${item[key]}"` : item[key]
337+
if (key === 'tags') {
338+
var tags = '"'
339+
if (item[key].length > 0) {
340+
item[key].forEach(tag => {
341+
tags += '(' + tag.key + ',' + tag.value + ')'
342+
})
343+
}
344+
result += tags + '"'
345+
} else {
346+
result += typeof item[key] === 'string' && item[key].includes(columnDelimiter) ? `"${item[key]}"` : item[key]
347+
}
338348
ctr++
339349
})
340350
result += lineDelimiter

0 commit comments

Comments
 (0)