Sha256: c9af2e8ba1fb0276e109e6a8f535835d3998ca5dac668ce1d8720dbd32bbf670

Contents?: true

Size: 1.01 KB

Versions: 59

Compression:

Stored size: 1.01 KB

Contents

import React from 'react';
import PropTypes from 'prop-types';
import { translate as __ } from 'foremanReact/common/I18n';
import { foremanUrl } from '../../../../../../ForemanRhCloudHelpers';

const Toast = ({ syncHosts, disconnectHosts }) => {
  const totalHosts = syncHosts + disconnectHosts;
  return (
    <span>
      <p>
        {__('Hosts with subscription in organization: ')}
        <strong>{totalHosts}</strong>
      </p>
      <p>
        {__('Successfully synced hosts: ')}
        <strong>{syncHosts}</strong>
      </p>
      <p>
        {__('Disconnected hosts: ')}
        <strong>{disconnectHosts}</strong>
      </p>
      <p>
        {__('For more info, please visit the')}{' '}
        <a
          href={foremanUrl('/hosts')}
          target="_blank"
          rel="noopener noreferrer"
        >
          {__('hosts page')}
        </a>
      </p>
    </span>
  );
};

Toast.propTypes = {
  syncHosts: PropTypes.number.isRequired,
  disconnectHosts: PropTypes.number.isRequired,
};

export default Toast;

Version data entries

59 entries across 59 versions & 1 rubygems

Version Path
foreman_rh_cloud-9.0.59 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-11.0.2 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-11.0.1 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-11.0.0 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.58 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-10.0.2 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.57 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-10.0.1 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.56 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.55 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.54 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.53 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.52 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-8.0.52 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-9.0.51 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-8.0.51 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-7.0.48 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-7.0.47 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-8.0.50 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js
foreman_rh_cloud-8.0.49 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/components/Toast.js