diff --git a/frontend/src/component/common/InstanceStatus/InstanceStatusBar.tsx b/frontend/src/component/common/InstanceStatus/InstanceStatusBar.tsx index 5a58297086..27c950139d 100644 --- a/frontend/src/component/common/InstanceStatus/InstanceStatusBar.tsx +++ b/frontend/src/component/common/InstanceStatus/InstanceStatusBar.tsx @@ -13,6 +13,7 @@ import { isTrialInstance, } from 'utils/instanceTrial'; import { formatDistanceToNowStrict, parseISO } from 'date-fns'; +import useUiConfig from '../../../hooks/api/getters/useUiConfig/useUiConfig'; const StyledWarningBar = styled('aside')(({ theme }) => ({ position: 'relative', @@ -132,13 +133,17 @@ const StatusBarExpiresLater = ({ instanceStatus }: IInstanceStatusBarProps) => { const BillingLink = ({ instanceStatus }: IInstanceStatusBarProps) => { const { hasAccess } = useContext(AccessContext); + const { uiConfig } = useUiConfig(); const navigate = useNavigate(); if (!hasAccess(ADMIN)) { return null; } - if (instanceStatus.plan === InstancePlan.ENTERPRISE) { + if ( + instanceStatus.plan === InstancePlan.ENTERPRISE && + uiConfig.billing !== 'pay-as-you-go' + ) { return null; }