1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

display last-applied-configuration annotation in detail-view, but filter it in search fields still (#943)

Signed-off-by: Yangjun Wang <yangjun.wang@wartsila.com>

Co-authored-by: Yangjun Wang <yangjun.wang@wartsila.com>
This commit is contained in:
Yangjun Wang 2020-09-28 17:24:54 +03:00 committed by GitHub
parent 6b231c97aa
commit bc228c9e36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -115,12 +115,12 @@ export class KubeObject implements ItemObject {
return KubeObject.stringifyLabels(this.metadata.labels);
}
getAnnotations(): string[] {
getAnnotations(filter = false): string[] {
const labels = KubeObject.stringifyLabels(this.metadata.annotations);
return labels.filter(label => {
return filter ? labels.filter(label => {
const skip = resourceApplierApi.annotations.some(key => label.startsWith(key));
return !skip;
})
}) : labels;
}
getOwnerRefs() {
@ -138,7 +138,7 @@ export class KubeObject implements ItemObject {
getNs(),
getId(),
...getLabels(),
...getAnnotations(),
...getAnnotations(true),
]
}