Sha256: c6d8b7d448e6ed3b56a2fe5872301a2c969c2f33cd8b7178c4d703a9e2bbae2d
Contents?: true
Size: 954 Bytes
Versions: 11
Compression:
Stored size: 954 Bytes
Contents
import React from 'react'; import PropTypes from 'prop-types'; import { useQuery } from '@apollo/client'; import { translate as __ } from 'foremanReact/common/I18n'; import OvalContentsShow from './OvalContentsShow'; import { encodeId } from '../../../helpers/globalIdHelper'; import ovalContent from '../../../graphql/queries/ovalContent.gql'; const WrappedOvalContentsShow = props => { const id = encodeId('ForemanOpenscap::OvalContent', props.match.params.id); const useFetchFn = componentProps => useQuery(ovalContent, { variables: { id } }); const renameData = data => ({ ovalContent: data.ovalContent }); return ( <OvalContentsShow {...props} fetchFn={useFetchFn} renameData={renameData} resultPath="ovalContent" emptyStateTitle={__('No OVAL Content found')} /> ); }; WrappedOvalContentsShow.propTypes = { match: PropTypes.object.isRequired, }; export default WrappedOvalContentsShow;
Version data entries
11 entries across 11 versions & 1 rubygems