Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ function renderTime(date, aggregationInterval) {
}
}

function showLinksMenuForItem(item) {
const canConfigureRules = (isRuleSupported(item) && checkPermission('canUpdateJob'));
function showLinksMenuForItem(item, showViewSeriesLink) {
const canConfigureRules = (isRuleSupported(item.source) && checkPermission('canUpdateJob'));
return (canConfigureRules ||
item.isTimeSeriesViewRecord ||
(showViewSeriesLink && item.isTimeSeriesViewRecord) ||
item.entityName === 'mlcategory' ||
item.customUrls !== undefined);
}
Expand Down Expand Up @@ -248,7 +248,7 @@ export function getColumns(
});
}

const showLinks = (showViewSeriesLink === true) || items.some(item => showLinksMenuForItem(item));
const showLinks = items.some(item => showLinksMenuForItem(item, showViewSeriesLink));

if (showLinks === true) {
columns.push({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export function DescriptionCell({ actual, typical }) {
} = getMetricChangeDescription(actual, typical);

return (
<EuiFlexGroup gutterSize="s">
<EuiFlexGroup gutterSize="s" alignItems="center">
{iconType !== undefined &&
<EuiFlexItem grow={false}>
<EuiIcon
Expand Down
6 changes: 4 additions & 2 deletions x-pack/legacy/plugins/ml/public/formatters/format_value.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,10 @@ export function formatValue(value, mlFunction, fieldFormat, record) {
if (value.length === 1) {
return formatSingleValue(value[0], mlFunction, fieldFormat, record);
} else {
// Return with array style formatting.
const values = value.map(val => formatSingleValue(val, mlFunction, fieldFormat, record));
// Currently only multi-value response is for lat_long detectors.
// Return with array style formatting, with items formatted as numbers, rather than
// the default String format which is set for geo_point and geo_shape fields.
const values = value.map(val => formatSingleValue(val, mlFunction, undefined, record));
return `[${values}]`;
}
} else {
Expand Down