Sha256: 708ea9e0ef458006bcb7d9ec407f6ff8231710a4b6f567338aa18f217a9d50a7

Contents?: true

Size: 811 Bytes

Versions: 83

Compression:

Stored size: 811 Bytes

Contents

import React from 'react';
import { translate as __ } from 'foremanReact/common/I18n';
import { post } from 'foremanReact/redux/API';
import { CONFIGURE_CLOUD_CONNECTOR } from './CloudConnectorConstants';
import { inventoryUrl } from '../../../../ForemanInventoryHelpers';
import { foremanUrl } from '../../../../../ForemanRhCloudHelpers';

export const configureCloudConnector = () =>
  post({
    key: CONFIGURE_CLOUD_CONNECTOR,
    url: inventoryUrl('cloud_connector'),
    successToast: response => (
      <span>
        {__('Cloud connector setup is in progress now: ')}
        <a href={foremanUrl(`/job_invocations/${response.data.id}`)}>
          {__('Cloud connector job link')}
        </a>
      </span>
    ),
    errorToast: error => `${__('Cloud connector setup has failed: ')} ${error}`,
  });

Version data entries

83 entries across 83 versions & 1 rubygems

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