Selaa lähdekoodia

Merge pull request #108 from danielholmes/patch-1

Fixed incorrect image url in boolean when symfony configured to use asset
Thomas 14 vuotta sitten
vanhempi
commit
f20ef5da11
1 muutettua tiedostoa jossa 9 lisäystä ja 2 poistoa
  1. 9 2
      Resources/views/CRUD/list_boolean.html.twig

+ 9 - 2
Resources/views/CRUD/list_boolean.html.twig

@@ -11,5 +11,12 @@ file that was distributed with this source code.
 
 {% extends 'SonataAdminBundle:CRUD:base_list_field.html.twig' %}
 
-{% block field%}<img src="{{ asset('bundles/sonataadmin/famfamfam/') }}{% if value %}accept{% else %}exclamation{% endif %}.png" />{% endblock %}
-
+{% block field %}
+{% spaceless %}
+    {% if value %}
+        <img src="{{ asset('bundles/sonataadmin/famfamfam/accept.png') }}" />
+    {% else %}
+        <img src="{{ asset('bundles/sonataadmin/famfamfam/exclamation.png') }}" />
+    {% endif %}
+{% endspaceless %}
+{% endblock %}