mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Load release data on every details open
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
78b6753e94
commit
f672bff96c
@ -5,7 +5,7 @@
|
||||
|
||||
import "./release-details.scss";
|
||||
|
||||
import React from "react";
|
||||
import React, { useEffect } from "react";
|
||||
|
||||
import { Link } from "react-router-dom";
|
||||
import { DrawerItem, DrawerTitle } from "../../drawer";
|
||||
@ -35,6 +35,10 @@ interface Dependencies {
|
||||
const NonInjectedReleaseDetailsContent = observer(({ model }: Dependencies & ReleaseDetailsContentProps) => {
|
||||
const loadingError = model.loadingError.get();
|
||||
|
||||
useEffect(() => {
|
||||
model.load();
|
||||
}, []);
|
||||
|
||||
if (loadingError) {
|
||||
return (
|
||||
<div data-testid="helm-release-detail-error">
|
||||
@ -45,7 +49,6 @@ const NonInjectedReleaseDetailsContent = observer(({ model }: Dependencies & Rel
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
return (
|
||||
<div>
|
||||
<DrawerItem name="Chart" className="chart">
|
||||
@ -133,8 +136,8 @@ const ResourceGroup = ({
|
||||
</TableHead>
|
||||
|
||||
{resources.map(
|
||||
({ detailsUrl, name, namespace, uid }) => (
|
||||
<TableRow key={uid}>
|
||||
({ detailsUrl, name, namespace }) => (
|
||||
<TableRow key={name}>
|
||||
<TableCell className="name">
|
||||
{detailsUrl ? <Link to={detailsUrl}>{name}</Link> : name}
|
||||
</TableCell>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user