Skip to content

Commit fe8e5cc

Browse files
J9remmrflos
authored andcommitted
fix(tableau.twig): more stable if checkbox values are badly formatted
1 parent 734067d commit fe8e5cc

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tools/bazar/templates/tableau.twig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,8 @@ pour différencier les différents tableaux table_1 table_2 #}
4343
p => p.propertyName)) %}
4444
{% for info in columnsInfo %}
4545
{% set val = entry[info.propertyName] %}
46+
{# sanitize possible errors in values from checkbox #}
47+
{% set val = val is iterable ? val|filter(v => v == 1)|keys|join(',') : val %}
4648
{% set exportval = val %}
4749
{% if info.key is empty and displayvaluesinsteadofkeys and (optionsIfDisplayvaluesinsteadofkeys[info.propertyName] is not empty) %}
4850
{% if info.multivalues %}

0 commit comments

Comments
 (0)