File tree Expand file tree Collapse file tree 1 file changed +14
-9
lines changed Expand file tree Collapse file tree 1 file changed +14
-9
lines changed Original file line number Diff line number Diff line change 20
20
{%- endblock %}
21
21
22
22
{% block money_widget -%}
23
- <div class =" input-group" >
24
- {% set append = money_pattern starts with ' {{' %}
25
- {% if not append %}
26
- <span class =" input-group-addon" >{{ money_pattern | replace ({ ' {{ widget }}' :' ' }) }}</span >
27
- {% endif %}
23
+ {% set prepend = not (money_pattern starts with ' {{' ) %}
24
+ {% set append = not (money_pattern ends with ' }}' ) %}
25
+ {% if prepend or append %}
26
+ <div class =" input-group" >
27
+ {% if prepend %}
28
+ <span class =" input-group-addon" >{{ money_pattern | replace ({ ' {{ widget }}' :' ' }) }}</span >
29
+ {% endif %}
30
+ {{- block (' form_widget_simple' ) -}}
31
+ {% if append %}
32
+ <span class =" input-group-addon" >{{ money_pattern | replace ({ ' {{ widget }}' :' ' }) }}</span >
33
+ {% endif %}
34
+ </div >
35
+ {% else %}
28
36
{{- block (' form_widget_simple' ) -}}
29
- {% if append %}
30
- <span class =" input-group-addon" >{{ money_pattern | replace ({ ' {{ widget }}' :' ' }) }}</span >
31
- {% endif %}
32
- </div >
37
+ {% endif %}
33
38
{%- endblock money_widget %}
34
39
35
40
{% block percent_widget -%}
You can’t perform that action at this time.
0 commit comments