mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Fixing ns loadMetrics() this context
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
8b3df1d098
commit
0a3ede1876
@ -25,7 +25,7 @@ import React from "react";
|
|||||||
import { computed, makeObservable, observable, reaction } from "mobx";
|
import { computed, makeObservable, observable, reaction } from "mobx";
|
||||||
import { disposeOnUnmount, observer } from "mobx-react";
|
import { disposeOnUnmount, observer } from "mobx-react";
|
||||||
import { DrawerItem } from "../drawer";
|
import { DrawerItem } from "../drawer";
|
||||||
import { cssNames } from "../../utils";
|
import { boundMethod, cssNames } from "../../utils";
|
||||||
import { getMetricsForNamespace, IPodMetrics, Namespace } from "../../api/endpoints";
|
import { getMetricsForNamespace, IPodMetrics, Namespace } from "../../api/endpoints";
|
||||||
import { getDetailsUrl, KubeObjectDetailsProps } from "../kube-object";
|
import { getDetailsUrl, KubeObjectDetailsProps } from "../kube-object";
|
||||||
import { Link } from "react-router-dom";
|
import { Link } from "react-router-dom";
|
||||||
@ -72,6 +72,7 @@ export class NamespaceDetails extends React.Component<Props> {
|
|||||||
return limitRangeStore.getAllByNs(namespace);
|
return limitRangeStore.getAllByNs(namespace);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@boundMethod
|
||||||
async loadMetrics() {
|
async loadMetrics() {
|
||||||
this.metrics = await getMetricsForNamespace(this.props.object.getName(), "");
|
this.metrics = await getMetricsForNamespace(this.props.object.getName(), "");
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user