Pārlūkot izejas kodu

[search] Removed the 'no data' visibility check for Leaflet

Enrico Berti 10 gadi atpakaļ
vecāks
revīzija
f867dc0585

+ 1 - 1
apps/search/src/search/static/search/js/search.ko.js

@@ -307,7 +307,7 @@ var Query = function (vm, query) {
     self.start(0);
     vm.search();
   };
-  
+
   function getFilterByField(field) {
     var _fq = null;
     $.each(self.fqs(), function (index, fq) {

+ 3 - 3
apps/search/src/search/templates/search.mako

@@ -1460,7 +1460,7 @@ ${ dashboard.layout_skeleton() }
           <span class="label label-info" style="margin-left: 4px" data-bind="text: $data.properties.lat_sw, attr: {'title': '${ _('Latitude South West') }'"></span>
           <span class="label label-info" style="margin-left: 4px" data-bind="text: $data.properties.lon_sw, attr: {'title': '${ _('Longitude South West') }'"></span>
           ]
-          ${ _("TO") } 
+          ${ _("TO") }
           [
           <span class="label label-info" style="margin-left: 4px" data-bind="text: $data.properties.lat_ne, attr: {'title': '${ _('Latitude North East') }'"></span>
           <span class="label label-info" style="margin-left: 4px" data-bind="text: $data.properties.lon_ne, attr: {'title': '${ _('Longitude North East') }'"></span>
@@ -1468,8 +1468,8 @@ ${ dashboard.layout_skeleton() }
         </span>
       </div>
     </div>
-    <!-- /ko -->    
-    
+    <!-- /ko -->
+
   </div>
   <div class="clearfix"></div>
   <div class="widget-spinner" data-bind="visible: isLoading() &&  $root.query.fqs().length > 0">

+ 1 - 1
desktop/core/src/desktop/static/desktop/js/ko.charts.js

@@ -304,7 +304,7 @@ ko.bindingHandlers.leafletMapChart = {
     var _data = _options.transformer(valueAccessor().datum);
 
     function toggleVisibility() {
-      if (((_options.visible != null && _options.visible) || _options.visible == null || typeof _options == "undefined") && _data.length > 0) {
+      if (((_options.visible != null && _options.visible) || _options.visible == null || typeof _options == "undefined")) {
         $(element).show();
         $(element).siblings(".leaflet-nodata").remove();
       }