WIP for Reporting. Pulled out calculations to utility functions.

This commit is contained in:
Patrick Fic
2020-10-20 13:55:35 -07:00
parent 4290c8c497
commit 045346ce48
18 changed files with 345 additions and 57 deletions

View File

@@ -0,0 +1,49 @@
import { createSelector } from "reselect";
const selectReporting = (state) => state.reporting;
export const selectReportLoading = createSelector(
[selectReporting],
(reporting) => reporting.loading
);
export const selectDates = createSelector(
[selectReporting],
(reporting) => reporting.dates
);
export const selectScorecard = createSelector(
[selectReporting],
(reporting) => reporting.scoreCard
);
export const selectReportingError = createSelector(
[selectReporting],
(reporting) => reporting.error
);
export const selectReportData = createSelector(
[selectReporting],
(reporting) => reporting.data
);
// export const selectWatchedPaths = createSelector(
// [selectReporting],
// (application) => application.watchedPaths
// );
// export const selectWatcherError = createSelector(
// [selectReporting],
// (application) => application.watcherError
// );
// export const selectSelectedJobId = createSelector(
// [selectReporting],
// (application) => application.selectedJobId
// );
// export const selectSelectedJobTargetPc = createSelector(
// [selectReporting],
// (application) => application.selectedJobTargetPc
// );
// export const selectSettings = createSelector(
// [selectReporting],
// (application) => application.settings
// );