Ver Fonte

[search] Display the name of the 2d dimension in map if non edit mode

Only if there there is one obviously
Romain Rigaux há 10 anos atrás
pai
commit
c02b2f5
1 ficheiros alterados com 10 adições e 0 exclusões
  1. 10 0
      apps/search/src/search/templates/search.mako

+ 10 - 0
apps/search/src/search/templates/search.mako

@@ -1157,8 +1157,18 @@ ${ dashboard.layout_skeleton() }
         </div>
       </div>
       <div class="clearfix"></div>
+    </div>
 
+    <div class="margin-bottom-10" data-bind="visible: ! $root.isEditing()">
+      <div data-bind="with: $root.collection.getFacetById($parent.id())">
+        <!-- ko if: $data.properties.facets().length == 1 -->
+          <div class="margin-bottom-10">
+            <span data-bind="text: $data.properties.facets()[0].field"></span>
+          </div>
+        <!-- /ko -->
+      </div>
     </div>
+
     <div data-bind="with: $root.collection.getFacetById($parent.id())">
       <div data-bind="mapChart: {data: {counts: $parent.count, scope: $root.collection.getFacetById($parent.id).properties.scope()},
         transformer: mapChartDataTransformer,