Skip to content

Comments

[backport] PR #8646 to 5.x - Fix label on scripted field date histograms#8647

Merged
Bargs merged 1 commit into5.xfrom
jasper/backport/8646/5.x
Oct 13, 2016
Merged

[backport] PR #8646 to 5.x - Fix label on scripted field date histograms#8647
Bargs merged 1 commit into5.xfrom
jasper/backport/8646/5.x

Conversation

@elastic-jasper
Copy link
Contributor

Backport PR #8646

Commit 1:
Fix label on scripted field date histograms

Now that we support Painless scripted fields users can create scripted
date fields, and thus scripted date histograms. The label making method
for the date histogram agg was getting the field name in a way that was
incompatible with scripted fields, so I've added some fallback code for
that scenario. I looked through the rest of the makeLabel methods on all
the other aggs and they all correctly access the field displayName
already so this should only need fixed for date histograms.

Now with more lodash for safer access

Fixes elastic#8632

---------

**Commit 1:**
Fix label on scripted field date histograms

Now that we support Painless scripted fields users can create scripted
date fields, and thus scripted date histograms. The label making method
for the date histogram agg was getting the field name in a way that was
incompatible with scripted fields, so I've added some fallback code for
that scenario. I looked through the rest of the makeLabel methods on all
the other aggs and they all correctly access the field displayName
already so this should only need fixed for date histograms.

Now with more lodash for safer access

Fixes elastic#8632

* Original sha: fc635bc
* Authored by Matthew Bargar <mbargar@gmail.com> on 2016-10-12T22:30:15Z
@elastic-jasper elastic-jasper added the backport This PR is a backport of another PR label Oct 13, 2016
@Bargs Bargs merged commit df72ca5 into 5.x Oct 13, 2016
@epixa epixa changed the title [backport] PR #8646 to 5.x [backport] PR #8646 to 5.x - Fix label on scripted field date histograms Oct 13, 2016
@spalger spalger deleted the jasper/backport/8646/5.x branch October 19, 2016 18:53
airow pushed a commit to airow/kibana that referenced this pull request Feb 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants