Sha256: aa7bde56d4a3dd1e663d8f658074b9960ad6b62e4d8e93781e20ac64dad325de

Contents?: true

Size: 1.13 KB

Versions: 58

Compression:

Stored size: 1.13 KB

Contents

import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import {
  selectAPIResponse,
  selectAPIStatus,
  selectAPIErrorMessage,
} from 'foremanReact/redux/API/APISelectors';
import * as actions from './RemediationActions';
import RemediationModal from './RemediationModal';
import { REMEDIATIONS_API_KEY } from './RemediationTableConstants';
import {
  selectIsAllSelected,
  selectSearch,
  selectSelectedIds,
} from '../InsightsTable/InsightsTableSelectors';

// map state to props
const mapStateToProps = state => ({
  selectedIds: selectSelectedIds(state),
  remediations: selectAPIResponse(state, REMEDIATIONS_API_KEY).hits || [],
  status: selectAPIStatus(state, REMEDIATIONS_API_KEY),
  error: selectAPIErrorMessage(state, REMEDIATIONS_API_KEY),
  itemCount: selectAPIResponse(state, REMEDIATIONS_API_KEY).itemCount || 0,
  isAllSelected: selectIsAllSelected(state),
  query: selectSearch(state),
});

// map action dispatchers to props
const mapDispatchToProps = dispatch => bindActionCreators(actions, dispatch);

// export connected component
export default connect(mapStateToProps, mapDispatchToProps)(RemediationModal);

Version data entries

58 entries across 58 versions & 1 rubygems

Version Path
foreman_rh_cloud-9.0.59 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-11.0.2 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-11.0.1 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-11.0.0 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.58 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-10.0.2 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.57 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-10.0.1 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.56 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.55 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.54 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.53 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.52 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-8.0.52 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-9.0.51 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-8.0.51 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-7.0.48 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-7.0.47 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-8.0.50 webpack/InsightsCloudSync/Components/RemediationModal/index.js
foreman_rh_cloud-8.0.49 webpack/InsightsCloudSync/Components/RemediationModal/index.js