File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -143,11 +143,11 @@ export default class DataFormatter {
143
143
let lowestValue = Number . MAX_VALUE ;
144
144
145
145
tableData [ 0 ] . forEach ( ( datapoint ) => {
146
- if ( ! datapoint . geohash ) {
146
+ if ( ! datapoint [ this . ctrl . panel . tableGeohash ] ) {
147
147
return ;
148
148
}
149
149
150
- const encodedGeohash = datapoint . geohash ;
150
+ const encodedGeohash = datapoint [ this . ctrl . panel . tableGeohash ] ;
151
151
const decodedGeohash = decodeGeoHash ( encodedGeohash ) ;
152
152
153
153
const dataValue = {
Original file line number Diff line number Diff line change @@ -58,6 +58,10 @@ <h5 class="section-heading">Map Data Options</h5>
58
58
< label class ="gf-form-label width-12 "> Table Label Field</ label >
59
59
< input type ="text " class ="input-small gf-form-input width-10 " ng-model ="ctrl.panel.tableLabel " ng-change ="ctrl.refresh() " ng-model-onblur />
60
60
</ div >
61
+ < div class ="gf-form " ng-show ="ctrl.panel.locationData === 'table' ">
62
+ < label class ="gf-form-label width-12 "> Geohash Field</ label >
63
+ < input type ="text " class ="input-small gf-form-input width-10 " ng-model ="ctrl.panel.tableGeohash " ng-change ="ctrl.refresh() " ng-model-onblur />
64
+ </ div >
61
65
< div class ="gf-form " ng-show ="ctrl.panel.locationData === 'geohash' ">
62
66
< label class ="gf-form-label width-12 "> ES Metric Field</ label >
63
67
< input type ="text " class ="input-small gf-form-input width-10 " ng-model ="ctrl.panel.esMetric " ng-change ="ctrl.refresh() " ng-model-onblur />
Original file line number Diff line number Diff line change @@ -27,7 +27,8 @@ const panelDefaults = {
27
27
decimals : 0 ,
28
28
hideEmpty : false ,
29
29
hideZero : false ,
30
- stickyLabels : false
30
+ stickyLabels : false ,
31
+ tableGeohash : 'geohash'
31
32
} ;
32
33
33
34
const mapCenters = {
You can’t perform that action at this time.
0 commit comments