Skip to content

Commit

Permalink
Added restrictions and type to filtering filed for group by
Browse files Browse the repository at this point in the history
  • Loading branch information
VladLasitsa committed Nov 18, 2020
1 parent 7114db3 commit 9434271
Showing 1 changed file with 14 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ import {
import { FormattedMessage } from '@kbn/i18n/react';
import { QueryBarWrapper } from '../query_bar_wrapper';
import { getDefaultQueryLanguage } from '../lib/get_default_query_language';
import { VisDataContext } from './../../contexts/vis_data_context';
export class TablePanelConfig extends Component {
constructor(props) {
super(props);
Expand Down Expand Up @@ -115,13 +116,19 @@ export class TablePanelConfig extends Component {
/>
}
>
<FieldSelect
fields={this.props.fields}
value={model.pivot_id}
indexPattern={model.index_pattern}
onChange={this.handlePivotChange}
fullWidth
/>
<VisDataContext.Consumer>
{(visData) => (
<FieldSelect
fields={this.props.fields}
value={model.pivot_id}
indexPattern={model.index_pattern}
onChange={this.handlePivotChange}
uiRestrictions={visData.uiRestrictions}
type={'terms'}
fullWidth
/>
)}
</VisDataContext.Consumer>
</EuiFormRow>
</EuiFlexItem>
<EuiFlexItem>
Expand Down

0 comments on commit 9434271

Please sign in to comment.