use of 'csv_cell' twig filter refs #401

This commit is contained in:
Marc Ducobu 2015-02-18 13:13:00 +01:00
parent b40a1595c1
commit be759dd640
2 changed files with 3 additions and 3 deletions

View File

@ -2,9 +2,9 @@
{%- for choice in choices -%} {%- for choice in choices -%}
{% if choice['slug'] in selected %} {% if choice['slug'] in selected %}
{%- if choice['slug'] is not same as('_other') -%} {%- if choice['slug'] is not same as('_other') -%}
{{ choice['name']|localize_translatable_string|replace({'"':'""'})|raw }} {{ choice['name']|localize_translatable_string|csv_cell }}
{%- else -%} {%- else -%}
{{ choice['name']|replace({'"':'""'})|raw }} {{ choice['name']|csv_cell }}
{%- endif -%} {%- endif -%}
{% endif %} {% endif %}
{%- endfor -%} {%- endfor -%}

View File

@ -1 +1 @@
{% if text is not empty %}{{ text|replace({'"':'""'})|raw }}{% else %}{{ 'None'|trans }}{% endif %} {% if text is not empty %}{{ text|csv_cell}}{% else %}{{ 'None'|trans }}{% endif %}