瀏覽代碼

Fix template para mostrar mapa

Guillermo Espinoza 7 年之前
父節點
當前提交
f7f0965891
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      Resources/views/Leaflet/map.html.twig

+ 4 - 0
Resources/views/Leaflet/map.html.twig

@@ -16,7 +16,11 @@
 
 {% if object is defined %}
 <script type="text/javascript">
+    {% if object.extraData %}
     var dataValue = '{{ object.extraData|raw }}';
+    {% elseif object.location is defined %}
+    var dataValue = '{{ object.location.extraData|raw }}';
+    {% endif %}
 </script>
 {% endif %}