diff --git a/src/ui/public/index_patterns/_field.js b/src/ui/public/index_patterns/_field.js index ff983d56de68d..ac0668168945c 100644 --- a/src/ui/public/index_patterns/_field.js +++ b/src/ui/public/index_patterns/_field.js @@ -40,10 +40,10 @@ export default function FieldObjectProvider(Private, shortDotsFilter, $rootScope const indexed = !!spec.indexed; const scripted = !!spec.scripted; - const sortable = spec.name === '_score' || ((indexed || scripted) && type.sortable); - const filterable = spec.name === '_id' || scripted || (indexed && type.filterable); const searchable = !!spec.searchable || scripted; const aggregatable = !!spec.aggregatable || scripted; + const sortable = spec.name === '_score' || ((indexed || scripted || aggregatable) && type.sortable); + const filterable = spec.name === '_id' || scripted || ((indexed || searchable) && type.filterable); const visualizable = aggregatable; obj.fact('name');