fix: handle MAP annotations in search results

This commit is contained in:
Mazzella, Jesse D. (ARC-TI)[KBR Wyle Services, LLC] 2023-05-25 19:02:28 -07:00
parent 3f2c63c9d7
commit b51654efbb

View File

@ -98,6 +98,10 @@ export default {
}
return 'Could not find any matching Notebook entries';
} else if (this.result.annotationType === this.openmct.annotation.ANNOTATION_TYPES.MAP) {
const targetID = Object.keys(this.result.targets)[0];
const { layerName, name } = this.result.targets[targetID];
return layerName ? `${layerName} - ${name}` : name;
} else {
return this.result.targetModels[0].name;
}