diff --git a/public/i18n/en.yaml b/public/i18n/en.yaml index 7142e2120c..36baec9f1b 100644 --- a/public/i18n/en.yaml +++ b/public/i18n/en.yaml @@ -1108,6 +1108,7 @@ nodes: persistent-volume-claims: description: <0>PersistentVolumeClaim (PVC) is a request for the PersistentVolume resources. headers: + capacity: Capacity access-modes: Access Mode selector: Selector storage: Storage diff --git a/src/resources/PersistentVolumeClaims/PersistentVolumeClaimDetails.js b/src/resources/PersistentVolumeClaims/PersistentVolumeClaimDetails.js index b64449348a..0aa13b8313 100644 --- a/src/resources/PersistentVolumeClaims/PersistentVolumeClaimDetails.js +++ b/src/resources/PersistentVolumeClaims/PersistentVolumeClaimDetails.js @@ -18,6 +18,7 @@ import PersistentVolumeClaimCreate from './PersistentVolumeClaimCreate'; import { UI5Panel } from 'shared/components/UI5Panel/UI5Panel'; import { ResourceDescription } from 'resources/PersistentVolumeClaims'; import { Link } from 'shared/components/Link/Link'; +import { spacing } from '@ui5/webcomponents-react-base'; import './PersistentVolumeClaim.scss'; @@ -167,13 +168,10 @@ export const PVCConfiguration = pvc => { export function PersistentVolumeClaimDetails(props) { const { t } = useTranslation(); - const customColumns = [ + const customStatusColumns = [ { - header: t('common.headers.status'), - value: ({ status }) => - || { - EMPTY_TEXT_PLACEHOLDER, - }, + header: t('persistent-volume-claims.headers.access-modes'), + value: pvc => , }, ]; @@ -204,13 +202,46 @@ export function PersistentVolumeClaimDetails(props) { return ( + || { + EMPTY_TEXT_PLACEHOLDER, + } + } + customStatusColumns={customStatusColumns} + customConditionsComponents={[ + { + header: t('persistent-volume-claims.headers.capacity'), + value: pvc => + pvc.status.capacity ? ( + Object.entries(pvc?.status?.capacity).map(capacity => { + console.log(capacity); + return ( + + ); + }) + ) : ( +
+ {EMPTY_TEXT_PLACEHOLDER} +
+ ), + }, + ]} customComponents={[ PVCConfiguration, PVCPods, PVCSelectorSpecification, Events, ]} - customColumns={customColumns} description={ResourceDescription} singularName={t('persistent-volume-claims.name_singular')} createResourceForm={PersistentVolumeClaimCreate}