lml-main
Version:
This is now a mono repository published into many standalone packages.
17 lines • 1.13 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const redux_observable_1 = require("redux-observable");
const redux_rx_http_1 = require("redux-rx-http");
const actions_1 = require("../../frequencies/actions");
exports.postAutoAllocationGlobal = (action$, store) => action$.ofType(actions_1.SET_AUTO_ALLOCATION_GLOBAL)
.map((action) => {
const autoAllocationGlobal = action.autoAllocationGlobal;
const body = { autoAllocationGlobal };
return redux_rx_http_1.rxHttpPost('/v2/joblabel/switch', actions_1.POST_AUTO_ALLOCATION_GLOBAL, body);
});
exports.postAutoAllocationGlobalSuccess = (action$, store) => action$.ofType(actions_1.POST_AUTO_ALLOCATION_GLOBAL.SUCCESS)
.mapTo({ type: 'NOOP' });
exports.postAutoAllocationGlobalError = (action$, store) => action$.ofType(actions_1.POST_AUTO_ALLOCATION_GLOBAL.ERROR)
.mapTo({ type: 'NOOP' });
exports.postAutoAllocationGlobalEpics = redux_observable_1.combineEpics(exports.postAutoAllocationGlobal, exports.postAutoAllocationGlobalSuccess, exports.postAutoAllocationGlobalError);
//# sourceMappingURL=post-auto-allocation-global.js.map