Sha256: 0db17370b04ee0df2df476d50734482a6a03f021bc4c5f8c452ca470e9e896ca

Contents?: true

Size: 1.46 KB

Versions: 72

Compression:

Stored size: 1.46 KB

Contents

import {
  selectAPIStatus,
  selectAPIError,
  selectAPIResponse,
} from 'foremanReact/redux/API/APISelectors';
import { STATUS } from 'foremanReact/constants';
import { CONTENT_KEY, CONTENT_TYPES_KEY, CONTENT_ID_KEY, REPOSITORY_CONTENT_ID_KEY } from './ContentConstants';

export const selectContent = state =>
  selectAPIResponse(state, CONTENT_KEY) || {};

export const selectContentStatus = state =>
  selectAPIStatus(state, CONTENT_KEY) || STATUS.PENDING;

export const selectContentError = state =>
  selectAPIError(state, CONTENT_KEY);

export const selectContentTypes = state =>
  selectAPIResponse(state, CONTENT_TYPES_KEY) || {};

export const selectContentTypesStatus = state =>
  selectAPIStatus(state, CONTENT_TYPES_KEY) || STATUS.PENDING;

export const selectContentTypesError = state =>
  selectAPIError(state, CONTENT_TYPES_KEY);

export const selectContentDetails = state =>
  selectAPIResponse(state, CONTENT_ID_KEY);

export const selectContentDetailsStatus = state =>
  selectAPIStatus(state, CONTENT_ID_KEY) || STATUS.PENDING;

export const selectContentDetailsError = state =>
  selectAPIError(state, CONTENT_ID_KEY);

export const selectRepositoryContentDetails = state =>
  selectAPIResponse(state, REPOSITORY_CONTENT_ID_KEY);

export const selectRepositoryContentDetailsStatus = state =>
  selectAPIStatus(state, REPOSITORY_CONTENT_ID_KEY) || STATUS.PENDING;

export const selectRepositoryContentDetailsError = state =>
  selectAPIError(state, REPOSITORY_CONTENT_ID_KEY);

Version data entries

72 entries across 72 versions & 1 rubygems

Version Path
katello-4.14.2 webpack/scenes/Content/ContentSelectors.js
katello-4.15.0 webpack/scenes/Content/ContentSelectors.js
katello-4.15.0.rc2 webpack/scenes/Content/ContentSelectors.js
katello-4.15.0.rc1 webpack/scenes/Content/ContentSelectors.js
katello-4.14.1 webpack/scenes/Content/ContentSelectors.js
katello-4.14.0 webpack/scenes/Content/ContentSelectors.js
katello-4.14.0.rc3 webpack/scenes/Content/ContentSelectors.js
katello-4.14.0.rc2 webpack/scenes/Content/ContentSelectors.js
katello-4.14.0.rc1.1 webpack/scenes/Content/ContentSelectors.js
katello-4.14.0.rc1 webpack/scenes/Content/ContentSelectors.js
katello-4.13.1 webpack/scenes/Content/ContentSelectors.js
katello-4.13.0 webpack/scenes/Content/ContentSelectors.js
katello-4.12.1 webpack/scenes/Content/ContentSelectors.js
katello-4.13.0.rc1 webpack/scenes/Content/ContentSelectors.js
katello-4.12.0 webpack/scenes/Content/ContentSelectors.js
katello-4.12.0.rc3 webpack/scenes/Content/ContentSelectors.js
katello-4.12.0.rc2 webpack/scenes/Content/ContentSelectors.js
katello-4.12.0.rc1 webpack/scenes/Content/ContentSelectors.js
katello-4.11.1 webpack/scenes/Content/ContentSelectors.js
katello-4.11.0 webpack/scenes/Content/ContentSelectors.js