Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #38113 - Add a link to REX bootc job templates in image mode details card. #11272

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,19 @@
} from '@patternfly/react-core';
import CardTemplate from 'foremanReact/components/HostDetails/Templates/CardItem/CardTemplate';
import FontAwesomeImageModeIcon from '../../../../components/extensions/Hosts/FontAwesomeImageModeIcon';
import { createJob } from '../Tabs/customizedRexUrlHelpers';

const cardHeader = (
<>
<span style={{ marginRight: '0.5rem' }}>{__('Image mode details')}</span>
<FontAwesomeImageModeIcon />
</>
);
const actionUrl = (hostname) => createJob({

Check failure on line 20 in webpack/components/extensions/HostDetails/DetailsTabCards/ImageModeCard.js

View workflow job for this annotation

GitHub Actions / react-tests / Foreman develop Ruby 2.7 and Node 14

Unexpected parentheses around single function argument having a body with no curly braces

Check failure on line 20 in webpack/components/extensions/HostDetails/DetailsTabCards/ImageModeCard.js

View workflow job for this annotation

GitHub Actions / react-tests / Foreman develop Ruby 2.7 and Node 18

Unexpected parentheses around single function argument having a body with no curly braces
hostname,
feature: 'katello_bootc_action',
inputs: {},
});

const ImageModeCard = ({ isExpandedGlobal, hostDetails }) => {
const imageMode = hostDetails?.content_facet_attributes?.bootc_booted_image;
Expand All @@ -28,6 +34,7 @@
masonryLayout
isExpandedGlobal={isExpandedGlobal}
>
<a href={actionUrl(hostDetails.name)}>{__('Bootc action template')}</a>

Check failure on line 37 in webpack/components/extensions/HostDetails/DetailsTabCards/ImageModeCard.js

View workflow job for this annotation

GitHub Actions / react-tests / Foreman develop Ruby 2.7 and Node 14

'hostDetails.name' is missing in props validation

Check failure on line 37 in webpack/components/extensions/HostDetails/DetailsTabCards/ImageModeCard.js

View workflow job for this annotation

GitHub Actions / react-tests / Foreman develop Ruby 2.7 and Node 18

'hostDetails.name' is missing in props validation
<DescriptionList isHorizontal>
<DescriptionListGroup>
<Dt>{__('Running image')}</Dt>
Expand Down
Loading